ClassMicrosoft.VisualBasic.DateAndTime SyntaxDim result As Date = TimeValue(stringTime)
DescriptionThe TimeValue function converts stringDate to the Date data type, setting any date component to January 1, 1 AD. The interpretation of the time components in the expression is based on the locale setting of the local computer. Usage at a GlanceIf stringTime is invalid or Nothing, a runtime error is generated. Version DifferencesIn VB 6, TimeValue returns the time only. Under .NET, the function also returns the base date of January 1, 1 AD. See AlsoDateValue Function, TimeOfDay Property, TimeSerial Function, TimeString Property |