L
lcl_003
Unregistered / Unconfirmed
GUEST, unregistred user!
我在线程里有个过程访问了vcl,所以用了同步。但是我想在这个过程里传递一个参数,该怎么做?
unit ThreadUnit2;
interface
uses
Classes,sysutils,mmsystem,Dialogs,forms,Windows;
type
MyThread = class(TThread)
private
{ Private declarations }
protected
procedure Execute;
override;
public
procedure senddata21();
end;
procedure MyThread.Execute;
var
i:byte;
begin
Synchronize(senddata21);
end;
unit ThreadUnit2;
interface
uses
Classes,sysutils,mmsystem,Dialogs,forms,Windows;
type
MyThread = class(TThread)
private
{ Private declarations }
protected
procedure Execute;
override;
public
procedure senddata21();
end;
procedure MyThread.Execute;
var
i:byte;
begin
Synchronize(senddata21);
end;