试过了,不行,不知道是不是我的用法有问题,我的代码是这样写的:<br>procedure TForm6.FormCloseQuery(Sender: TObject; var CanClose: Boolean);<br>var<br> hanldmain:Thandle;<br> hanldtemp:Thandle;<br>begin<br> hanldmain:=FindWindow('TfrmMainForm','一卡通系统');<br> hanldtemp:= FindWindow('TForm5','Form5');<br> //PostMessage(hanldtemp,RegisterWindowMessage('TESTTEST'),0,3);<br> //SendMessage(主窗口.ClientHandle, WM_MDIACTIVATE, 子窗口.Handle, 0);<br> SendMessage(hanldmain, RegisterWindowMessage('TESTTEST'), hanldtemp, 0);<br>end;<br>楼上的麻烦帮我看一下!