COleDateTime.Constructorsconstructor
Create new **COleDateTime** objects initialized to the specified value.
No implementation located. This member is documented, but the source scan found no matching declaration. It is likely declared in a header this scan does not resolve, or provided by a macro.
Syntax
CONSTRUCTOR COleDateTime
CONSTRUCTOR COleDateTime (BYREF dateSrc AS COleDateTime)
CONSTRUCTOR COleDateTime (BYREF varSrc AS VARIANT)
CONSTRUCTOR COleDateTime (BYVAL dtSrc AS DATE_)
CONSTRUCTOR COleDateTime (BYVAL timeSrc AS LONGLONG)
CONSTRUCTOR COleDateTime (BYREF systimeSrc AS SYSTEMTIME)
CONSTRUCTOR COleDateTime (BYREF filetimeSrc AS FILETIME)
CONSTRUCTOR COleDateTime (BYVAL wDosDate AS DWORD, BYVAL wDosTime AS WORD)
CONSTRUCTOR COleDateTime (BYREF dbts AS DBTIMESTAMP)
CONSTRUCTOR COleDateTime (BYREF ud AS UDATE)
CONSTRUCTOR COleDateTime (BYVAL nYear AS WORD, BYVAL nMonth AS WORD, BYVAL nDay AS WORD, BYVAL nHour AS WORD, BYVAL nMin AS WORD, BYVAL nSec AS WORD)
CONSTRUCTOR COleDateTime (BYREF wsz AS WSTRING, BYVAL dwFlags AS DWORD = 0, BYVAL lcid AS LCID = LANG_USER_DEFAULT)
Parameters
| Name | Description | |
|---|---|---|
dateSrc | An existing COleDateTime object to be copied into the new COleDateTime object. | |
varSrc | An existing VARIANT data structure to be converted to a date/time value (VT_DATE) and copied into the new COleDateTime object. | |
dtSrc | A date/time ( DATE) value to be copied into the new COleDateTime object. | |
timeSrc | A LongInt value to be converted to a date/time value and copied into the new COleDateTime object. | |
systimeSrc | A SYSTEMTIME structure to be converted to a date/time value and copied into the new COleDateTime object. | |
filetimeSrc | A FILETIME structure to be converted to a date/time value and copied into the new COleDateTime object. Note that FILETIME uses Universal Coordinated Time (UTC), so if you pass a local time in the structure, your results will be incorrect. See File Times in the Windows SDK for more information. | |
nYear / nMonth / nDay / nHour / nMin / nSec | Indicate the date and time values to be copied into the new COleDateTime object. | |
wDosDate / wDosTime | MS-DOS date and time values to be converted to a date/time value and copied into the new COleDateTime object. | |
dbts | A reference to a DBTimeStamp structure containing the current local time. | |
ud | The UDATE value is converted and copied into this COleDateTime object. If the conversion is successful, the status of this object is set to valid; if unsuccessful, it is set to invalid. A UDATE structure represents an "unpacked" date. See the function VarDateFromUdate for more details. | |
wsz | A null-terminated unicode string which is to be parsed. This parameter can take a variety of formats. For example, the following strings contain acceptable date/time formats: "25 January 1996" "8:30:00" "20:30:00" "January 25, 1996 8:30:00" "8:30:00 Jan. 25, 1996" "1/25/1996 8:30:00" // always specify the full year, even in a 'short date' format. Note that the locale ID will also affect whether the string format is acceptable for conversion to a date/time value. In the case of VAR_DATEVALUEONLY, the time value is set to time 0, or midnight. In the case of VAR_TIMEVALUEONLY, the date value is set to date 0, meaning 30 December 1899. | |
dwFlags | Indicates flags for locale settings and parsing. LOCALE_NOUSEROVERRIDE Use the system default locale settings, rather than custom user settings. VAR_TIMEVALUEONLY Ignore the date portion during parsing. VAR_DATEVALUEONLY Ignore the time portion during parsing. | |
lcid | Indicates locale ID to use for the conversion. Default value: LANG_USER_DEFAULT. |
Description
Create new COleDateTime objects initialized to the specified value.
Remarks
The status of the new COleDateTime object is set to valid.
Reference
- Include file
COleDateTime.inc - Documented in DateTime/COleDateTime Class.md
- Topic: COleDateTime Class