I have the string "06-03-2016T06:42:44.252Z"
and I would like to convert it to a datetime.
The top answer from this post suggested using:
DateTime.Parse(string, null, System.Globalization.DateTimeStyles.RoundtripKind);
This works if I format my date like "2016-06-03T06:42:45Z"
but not "06-03-2016T06:42:44.252Z"
How can I convert "06-03-2016T06:42:44.252Z"
to datetime properly?
Thank you very much for your time. Please let me know if I am being unclear or if you need anything else from me.
I could not find another question on stack asking how to convert from this exact format and could not apply the strategies from them to my case. I can transform my string to match those used in the example I linked but I am losing a bit of precision and adding more work in the process. I would like to leave this question up and unmarked as a duplicate in hopes of finding a means of parsing my date format or confirming that it cannot be done.