Previous Document Next Document
CorelScriptTools.BuildDate

Function BuildDate(Year As Long, Month As Long, Day As Long) As Date

Member of CorelScriptTools

The BuildDate method assigns a date value to a date variable.

Parameter
Description
Year
Specifies the year to assign to a date variable
Month
Specifies the month to assign to a date variable. Valid values are from 1 to 12 inclusive.
Day
Specifies the day to assign to a date variable. Valid values are from 1 to 31 inclusive, depending on the Month setting.

  • The BuildDate method can accept only a date value between January 1, 1980 (date serial number 29221) and December 31, 2099 (date serial number 73050). If a date outside this range is specified, an error occurs.

In the following code example, the first line declares the date variable BigDay. This variable is then assigned the date January 14, 1996:

DIM BigDay AS DATE 
BigDay = BUILDDATE(1996, 1, 14) 

Previous Document Next Document Back to Top

Copyright 2007 Corel Corporation. All rights reserved.