level 1
怎么用free pascal 调出系统时间(即任务栏右下角的时间)包含年、月、日、时、分、秒。
2010年12月14日 13点12分
1
level 6
uses dos;
............
getdate(a,b,c,d) gettime(a,b,c,d)
.............
2010年12月14日 16点12分
2
level 1
表示对Free pascal不是很了解……貌似只会用些简单的语句,所以帮个忙说清楚点吧!
2010年12月15日 14点12分
7
level 6
3L,gettime是分秒,getdate是年月日
2010年12月16日 05点12分
8
level 5
握查了,TDATETIME只能在delphi里面用...
2010年12月16日 06点12分
9
level 1
额,没关系,8L的已经能用了……可怎么显示星期几呢?
2010年12月16日 11点12分
10
level 1
哦,明白了,明白了…… date里面第四个变量就是星期几啊。
2010年12月17日 04点12分
11
level 6
要是不知道第四个变量是星期几的话,可以去写一个蔡勒公式的…
2010年12月18日 08点12分
12
level 1
。。什么叫蔡勒公式?怎么让系统一分钟读取一次时间?求解啊……
2010年12月18日 14点12分
13
level 9
repeatgettime(a,b,c,d);//时,分,秒,毫秒
getdate(e,f,g,h);//年,月,日,星期
delay(60000);//让系统一分钟读取一次时间
writeln(a,' ',b,' ',c,' ',d,' ',e,' ',f,' ',g,' ',h);
until 0=1;
2010年12月20日 10点12分
14
level 9
repeat
gettime(a,b,c,d);//时,分,秒,毫秒
getdate(e,f,g,h);//年,月,日,星期
delay(60000);//让系统一分钟读取一次时间
writeln(a,' ',b,' ',c,' ',d,' ',e,' ',f,' ',g,' ',h);
until 0=1;
楼上写错了
2010年12月20日 10点12分
15
level 1
60000又是怎么得来的? 0=1又是什么意思呢?
2010年12月20日 13点12分
16
level 1
??出现错误。。。用错语句了吧…… DOS下有这句吗?CRT才有吧……
2010年12月20日 13点12分
18
level 6
Delay我不知道uses什么,但getdata可以只要dos
2010年12月21日 05点12分
20
level 6
至于蔡勒公式的话,你要么看看百度百科,要么看看我的博客(百度上搜Boolean93 蔡勒公式,里面的那个网易Blog就是我的了)
2010年12月21日 05点12分
21