Convert UTC format date to datetime

remya1000

Well-known member
Joined
Mar 29, 2007
Messages
122
Programming Experience
Beginner
How to convert UTC formate time to local time.using vb.net.

In my application in some point of the execution i need to retrieve a date,but instead of date i get some numbers,for example "200706062000".
and it means 2007 June 06 20:00.

How to convert these numbers to a date,more specifically to local time?
in this format "#06/06/2007 08:00 PM#"

if you have any idea please let me know. if example is there that will be great helpful to me.

thanks in advance.
 
its working.... i tried this format and its working.

Dim gstart As New DateTime

gstart = System.DateTime.ParseExact(Trim(xmlRdr.Value), "yyyyMMddHHmm", System.Globalization.DateTimeFormatInfo.InvariantInfo).ToString("MM/dd/yyyy HH:mm")
 
Back
Top