delphi怎么获取edit1里的数值?
比如这个,重置系统时间,新手求看varyourtime:Tsystemtime;a,b,c,d,e,f:integer;g,h,i,j,k,l:string;beginw...
比如这个,重置系统时间,新手求看
var
yourtime:Tsystemtime;
a,b,c,d,e,f:integer;
g,h,i,j,k,l:string;
begin
with yourtime do
begin
g:=edit1.text;
a:=strtoint(g);
wyear:=a;
h:=edit2.Text;
b:=strtoint(h);
wmonth:=b;
i:=edit2.Text;
c:=strtoint(i);
wmonth:=c;
j:=edit2.Text;
d:=strtoint(j);
wmonth:=d;
k:=edit2.Text;
e:=strtoint(k);
wmonth:=e;
l:=edit2.Text;
f:=strtoint(l);
wmonth:=f;
end;
setsystemtime(yourtime);
end;
出什么问题了?怎么更改不了? 展开
var
yourtime:Tsystemtime;
a,b,c,d,e,f:integer;
g,h,i,j,k,l:string;
begin
with yourtime do
begin
g:=edit1.text;
a:=strtoint(g);
wyear:=a;
h:=edit2.Text;
b:=strtoint(h);
wmonth:=b;
i:=edit2.Text;
c:=strtoint(i);
wmonth:=c;
j:=edit2.Text;
d:=strtoint(j);
wmonth:=d;
k:=edit2.Text;
e:=strtoint(k);
wmonth:=e;
l:=edit2.Text;
f:=strtoint(l);
wmonth:=f;
end;
setsystemtime(yourtime);
end;
出什么问题了?怎么更改不了? 展开
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询