单击button时,timer.Enabled:=true;执行ontimer事件。 执行完了后,timer.Enabled:=false; 可再单击button,为什么ontimer下的事件不执行了呢?
----------------------------------------------
Function IThink(Boy,Girl : TPerson) : String; begin if Boy.钱 < 10W then Girl.Say(''滚!'') else begin if Girl.Anser = ''我愿意'' then Result := ''结婚'' else Result := IntToStr(88); end; 风过不折→百炼成尧 QQ: 7315910
不是这个原因哈。 这个我早就试过了,还是一样的没法。 大家帮帮忙三。
----------------------------------------------
Function IThink(Boy,Girl : TPerson) : String; begin if Boy.钱 < 10W then Girl.Say(''滚!'') else begin if Girl.Anser = ''我愿意'' then Result := ''结婚'' else Result := IntToStr(88); end; 风过不折→百炼成尧 QQ: 7315910
不哈,不大啊。 你试着把你的代码中的label1换成label2试试,好像就不行了。
----------------------------------------------
Function IThink(Boy,Girl : TPerson) : String; begin if Boy.钱 < 10W then Girl.Say(''滚!'') else begin if Girl.Anser = ''我愿意'' then Result := ''结婚'' else Result := IntToStr(88); end; 风过不折→百炼成尧 QQ: 7315910
procedure TForm1.Timer1Timer(Sender: TObject); var i:integer; begin i:=StrToInt(Label1.Caption); inc(i); label1.Caption:=IntToStr(i); label2.Caption:=IntToStr(i); end; 代码就这么简单啊,为什么把第一个label去了就没法进行了?
----------------------------------------------
Function IThink(Boy,Girl : TPerson) : String; begin if Boy.钱 < 10W then Girl.Say(''滚!'') else begin if Girl.Anser = ''我愿意'' then Result := ''结婚'' else Result := IntToStr(88); end; 风过不折→百炼成尧 QQ: 7315910