Receiveunit.pas
上传用户:psxgmh
上传日期:2013-04-08
资源大小:15112k
文件大小:1k
- unit Receiveunit;
- interface
- uses
- Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
- Dialogs, StdCtrls, Buttons;
- type
- TForm1 = class(TForm)
- Edit1: TEdit;
- Label1: TLabel;
- private
- { Private declarations }
- public
- procedure Capturemessage(var CopyData:TWmCopyData);message WM_COPYDATA;
- { Public declarations }
- end;
- var
- Form1: TForm1;
- implementation
- {$R *.dfm}
- procedure TForm1.Capturemessage(var CopyData:TWmCopyData);
- begin
- Edit1.text:=StrPas(CopyData.CopyDataStruct^.lpData);//接收数据获取数据并显示
- end;
- end.