DosDateTimeToVariantTime(3w)

DosDateTimeToVariantTime3w

Usage

INT DosDateTimeToVariantTime
(
USHORT wDosDate,
USHORT wDosTime,
double* pDateOut
)

Overview

Convert a Dos format date and time into variant VT_DATE format.

Params

wDosDate [In] Dos format date.

wDosTime [In] Dos format time.

pDateOut [Out] Destination for VT_DATE format.

Returns

Success: TRUE. pDateOut contains the converted time.

Failure: FALSE, if wDosDate or wDosTime are invalid (see notes).

Notes

- Dos format dates can only hold dates from 1-Jan-1980 to 31-Dec-2099.

- Dos format times are accurate to only 2 second precision.

- The format of a Dos Date is:

Bits Values Meaning

---- ------ -------

0-4 1-31 Day of the week. 0 rolls back one day. A value greater than

the days in the month rolls forward the extra days.

5-8 1-12 Month of the year. 0 rolls back to December of the previous

year. 13-15 are invalid.

9-15 0-119 Year based from 1980 (Max 2099). 120-127 are invalid.

- The format of a Dos Time is:

Bits Values Meaning

---- ------ -------

0-4 0-29 Seconds/2. 30 and 31 are invalid.

5-10 0-59 Minutes. 60-63 are invalid.

11-15 0-23 Hours (24 hour clock). 24-32 are invalid.

Implementation

Declared in "oleauto.h".

Implemented in "dlls/oleaut32/variant.c".

Debug channel "variant".

Releases

4 releases since Debian 4.0 (Etch); the text changed 3 times.

  1. 4.0
  2. 5.0
  3. 6.0
  4. 7

From libwine-dev 1.4.1-4 in Debian 7 (Wheezy). Parsed by carta from the page's man source.