How do I reliably extract the date from a string, given that it could be in a number formats and positions?

I have a list of folder names in that could be in a variety of formats:
368446-SN.24260046-12.08.2026
368446-SN.24260046-12.08.26
368446-SN.24260046.12-08.26 etc.
Up until now, the date portion has always been at the end of the name, but that is not guarenteed.
How do I relaible extract the date from these strings and return it in the format of dd-mm-yyyy?
I’ve tried using digitsPattern but that hasn’t proved relaible, given the varying form of the date.I have a list of folder names in that could be in a variety of formats:
368446-SN.24260046-12.08.2026
368446-SN.24260046-12.08.26
368446-SN.24260046.12-08.26 etc.
Up until now, the date portion has always been at the end of the name, but that is not guarenteed.
How do I relaible extract the date from these strings and return it in the format of dd-mm-yyyy?
I’ve tried using digitsPattern but that hasn’t proved relaible, given the varying form of the date. I have a list of folder names in that could be in a variety of formats:
368446-SN.24260046-12.08.2026
368446-SN.24260046-12.08.26
368446-SN.24260046.12-08.26 etc.
Up until now, the date portion has always been at the end of the name, but that is not guarenteed.
How do I relaible extract the date from these strings and return it in the format of dd-mm-yyyy?
I’ve tried using digitsPattern but that hasn’t proved relaible, given the varying form of the date. string processing, date extraction MATLAB Answers — New Questions

​

Leave a Reply

Your email address will not be published. Required fields are marked *