设置时间还有时区问题
procudure settime(time:Tdatetime);
var newtime : Tsystemtime;
Hour,Min,Sec,Msec : Word;
date : Tdate;
begin
DecodeTime(Time,Hour,Min,Sec,Msec);
If Hour<8 then
Hour:=16+Hour
else
Hour:=Hour-8;
Time:=Encodetime(Hour,Min,Sec,Msec);
DateTimeToSystemTime(time,newtime);
SetSystemTime(Newtime);
end