I have a requirement to append the email received date to the email file name when saving to a folder. It is working fine in my system. Date format is like:
Here is my code
I ran the same .xaml file in my colleague’s system. But the date format in her system is like:
It is the same .xaml code running in both our systems. How do I make sure that her date format is same as mine?
@jack.chan , email is of type mailmessage.
email.Headers(“Date”) also gave the same result as email.Date.
So I converted the date in her code as given below:
Datetime.Parse(email.Headers(“Date”),System.Globalization.CultureInfo.InvariantCulture).ToString(“MM/dd/yyyy”)