当前位置: 首页 > 网络学院 > 客户端脚本教程 > VBScript > VBScript DateSerial 函数
The DateSerial function returns a Variant of subtype Date for a specified year, month, and day.
DateSerial 函数可对于指定的年、月、日,返回 Date 子类型的 Variant
DateSerial(year,month,day) |
参数 | 描述 |
---|---|
year | Required. A number between 100 and 9999, or a numeric expression. Values between 0 and 99 are interpreted as the years 1900–1999. For all other year arguments, use a complete four-digit year 必选项。从 100 到 9999 之间的数字或数值表达式 |
month | Required. Any numeric expression 必选项。任意数值表达式。 |
day | Required. Any numeric expression 必选项。任意数值表达式。 |
document.write(DateSerial(1996,2,3) & "<br />") 输出: 2/3/1996 |