请问以下代码那里错了呢?谢谢??
unit Unit1;interfaceuses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls;type
TForm1 = class(TForm)
Edit1: TEdit;
Button1: TButton;
procedure Button1Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;var
Form1: TForm1;implementationuses Unit2;{$R *.dfm}procedure TForm1.Button1Click(Sender: TObject);
var thr:MyThread;
begin
thr.resume;
end;end.
unit Unit1;interfaceuses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls;type
TForm1 = class(TForm)
Edit1: TEdit;
Button1: TButton;
procedure Button1Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;var
Form1: TForm1;implementationuses Unit2;{$R *.dfm}procedure TForm1.Button1Click(Sender: TObject);
var thr:MyThread;
begin
thr.resume;
end;end.
解决方案 »
- 三层,客户端掉用应用服务器端方法(Method)时出的问题
- 我写了个定时关机程序,在调试时可以正常运行,但我运行.exe可执行文件时,却没反应!
- 请问如何遍历一个文件夹的所有文件
- 求一个cell编辑器源代码 就是类似与execl一样 功能一般就行
- 我不想用Rave5自带的报表预览界面,好难看,请问能否自己定制报表预览界面?如何定制?
- 问下大家现在在用的Delphi版本?都在用那些?
- 请问什么是VFP的支持库
- 如何通过程序进行ODBC的设置
- with ... do....什么意思?怎么用呢?
- 如何用ODBC连接到其它计算机上的数据库系统啊?求助啊?!
- 我又迷茫了!在Java和.Net大行其道的今天,Delphi的路在何方?
- Groupbox中加入多个radiobutton按钮时,如何指定某个radiobutton为默认而显示在运行时的界面上?
Classes,sysutils;type
MyThread = class(TThread)
private
{ Private declarations }
// procedure Create;
protected
procedure Execute; override;
procedure se;
public
end;implementationuses Unit1;
{ MyThread }
procedure MyThread.Execute;
var
tem:integer;
begin
{ Place thread code here }
while true do
begin
self.Synchronize(se);
end
end;
procedure MyThread.se;
begin
Form1.Edit1.Text:='121';
end;
end.
?????????????????????????????
procedure TForm1.Button1Click(Sender: TObject);
var thr:MyThread;
begin
thr := MyThread.Create(True);
thr.resume;
end;