Date.Constructor(Year as Integer, Month as Integer = 1, Day as Integer = 1, hour as Integer = 0, minute as Integer = 0, second as Integer = 0, GMTOffset as double)

From Xojo Documentation

Revision as of 19:07, 3 September 2020 by THill (talk | contribs) (Text replacement - "{{DeprecatedItemItem|" to "{{DeprecatedItem|")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)


Date.Constructor(Year as Integer, Month as Integer, Day as Integer, Hour as Integer, Minute as Integer, Second as Integer, GMTOffset as Double)

Introduced 2009r2

Sets the new date object to the passed Year, Month, Day, Hour, Minute, Second, and GMTOffset. Requires setting the GMT offset.

Sample Code

The following code sets the date/time value using the constructor and displays it in a Label.

Dim d As New Date(1956, 8, 13, 8, 23, 0, -7)
Label1.Text = d.SQLDateTime