如题
解决方案 »
- 用IDHTTP怎么把带分行的数据发送出去呢。。。。
- 具备小计、合计,有点难度的特定格式查询
- 谁用过indy的IdTcpServer来处理数据?或做过socket通讯的高手看看,就剩这点分了,头大
- nmstrm 控件在delphi7下没有,我该如何安装
- tdxedit,tdxeditbutton,tdxdbgrid......等等以dx开头的到底是什么控件,包名叫什么
- 请问怎么得到SQL SERVER安装在哪个目录中?
- 关于ListView的使用...
- 高手请进:关于delphi中利用Word模板的问题.
- 一个关于线程的问题?
- 关于Activex的一些问题
- 请问Report Machine报表中,如果给TrmGridReport动态添加列
- fastreport sum
systemtime:Tsystemtime;
DateTime:TDateTime;
begin
DateTime:=StrToDateTime(Edit1.text); //获得时间(TDateTime格式)
DateTimeToSystemTime(DateTime,systemtime); //把Delphi的TDateTime格式转化为API的TSystemTime格式
SetLocalTime(SystemTime); //设置系统时间
GetLocalTime(SystemTime); //读取系统时间
DateTime:=SystemTimeToDateTime(SystemTime); //把API的TSystemTime格式 转化为 Delphi的TDateTime格式
Edit2.Text:=DateTimeToStr(DateTime); //显示当前系统的时间
end; 关键点是:SetLocalTime(SystemTime); 里面的参数自己调下就可以了
在sysutils单元里有如下几个变量
DateSeparator: Char;
ShortDateFormat: string;
LongDateFormat: string;
TimeSeparator: Char;
ShortTimeFormat: string;
LongTimeFormat: string;
对这些变量进行设置