Convert UTC string to UTC DateTime

Posted on 2009-02-22
Last Modified: 2012-05-06
Hi Experts,

How do I convert a string of a UTC time "22 Feb 2009 14:00:00" to a UTC DateTime. If I use the TimeZoneInfo.ConvertTimeFromUtc() method this subtracts the offset again. I want the time to remain the same but be of UTC DateTime type.
Question by:DColin
    LVL 15

    Assisted Solution

    by:Praveen Venu
    Have you tried this?
    Dim str As String = "22 Feb 2009 14:00:00"
    Dim dt As DateTime = CDate(str)

    Open in new window

    LVL 14

    Accepted Solution


    Featured Post

    Top 6 Sources for Identifying Threat Actor TTPs

    Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

    Join & Write a Comment

    Suggested Solutions

    This article explains how to create and use a custom WaterMark textbox class.  The custom WaterMark textbox class allows you to set the WaterMark Background Color and WaterMark text at design time.   IMAGE OF WATERMARKS STEPS Create VB …
    1.0 - Introduction Converting Visual Basic 6.0 (VB6) to Visual Basic 2008+ (VB.NET). If ever there was a subject full of murkiness and bad decisions, it is this one!   The first problem seems to be that people considering this task of converting…
    Migrating to Microsoft Office 365 is becoming increasingly popular for organizations both large and small. If you have made the leap to Microsoft’s cloud platform, you know that you will need to create a corporate email signature for your Office 365…
    how to add IIS SMTP to handle application/Scanner relays into office 365.

    745 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    18 Experts available now in Live!

    Get 1:1 Help Now