I have a date/time string that looks like the following:
Wed Sep 21 2011 12:35 PM Pacific
How do I format a DateTime to look like this?
Thank you!
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
The bit before the time zone is easy, using a custom date and time format string:
However, I believe that the .NET date/time formatting will not give you the “Pacific” part. The best it can give you is the time zone offset from UTC. That’s fine if you can get the time zone name in some other way.
A number of
TimeZoneInfoidentifiers include the word Pacific, but there isn’t one which is just “Pacific”.