Parse Date: December 7, 2007 : Date Parse « Date Time « VB.Net Tutorial

Home
VB.Net Tutorial
1.Language Basics
2.Data Type
3.Operator
4.Statements
5.Date Time
6.Class Module
7.Development
8.Collections
9.Generics
10.Attributes
11.Event
12.LINQ
13.Stream File
14.GUI
15.GUI Applications
16.Windows Presentation Foundation
17.2D Graphics
18.I18N Internationlization
19.Reflection
20.Regular Expressions
21.Security
22.Socket Network
23.Thread
24.Windows
25.XML
26.Database ADO.net
27.Design Patterns
VB.Net Tutorial » Date Time » Date Parse 




Public Class Tester
    Public Shared Sub Main
        Dim testDate As String
        Dim results As New System.Text.StringBuilder

        ' ----- Test a date.
        testDate = "December 7, 2007"
        If (IsDate(testDate= TrueThen _
           results.AppendLine(Date.Parse(testDate).ToString)

        Console.WriteLine(results.ToString())

    End Sub

End Class
07/12/2007 12:00:00 AM














5.4.Date Parse
5.4.1.Parse Date
5.4.2.Parse Date: Feb 3, 2007
5.4.3.Parse Date: 23:57:58
5.4.4.Parse Date: December 7, 2007
5.4.5.Parse Date: 2007-07-04T23:59:59
5.4.6.Parse Date: 2007-07-04T23:59:59Z
5.4.7.Use Parse method to convert a string into a DateTime
java2s.com  | Contact Us | Privacy Policy
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.