请输入您要查询的百科知识:

 

词条 getdate
释义

函数名: getdate

功 能: 取DOS日期

用 法: void getdate(struct *dateblk);

程序例:

#include<stdio.h>

#include <dos.h>

int main(void)

{

struct date d;

getdate(&d);

printf("The current year is: %d\",

d.da_year);

printf("The current day is: %d\",

d.da_day);

printf("The current month is: %d\",

d.da_mon);

return 0;

}

备注

在VC++6.0中运行上述程序不能通过,原因是此版本的<dos.h>中不包含getdate函数。

但在TroboC 中运行可以通过。

随便看

 

百科全书收录4421916条中文百科知识,基本涵盖了大多数领域的百科知识,是一部内容开放、自由的电子版百科全书。

 

Copyright © 2004-2023 Cnenc.net All Rights Reserved
更新时间:2025/3/14 10:05:00