Sometimes, you stumble across weird data formats, i.e. in log files, that won’t autoconvert to DateTime objects. Here is a quick approach for parsing such date and time information:
$weirdDate = ' 03 12 --- 1988 '
[ DateTime ] :: ParseExact ( $weirdDate , ' MM dd --- yyyy ' , $null )
As you can see, ParseExact() does the job for you and wants you to specify the custom date and time format, using the standard...