Witam mam problem z odebraniem komunikatu TwmCopyData w WndProc to kod:
type
Tmydata = record
ProcessId: Cardinal;
Hwnd: Cardinal;
end;
var
Wnd:TWndClass;
Msg:TMsg;
apphnd:hwnd;
CDS: TCopyDataStruct;
function WndProc(hwnd, message: Cardinal; wParam, lParam: integer): Integer; stdcall;
var
wmCopyData:TwmCopyData;
begin
Result:=0;
case message of
WM_CopyData:
begin
wmCopyData.CopyDataStruct:= << tu chce wsadzić Lparam bo komunikat wysyłany jest tak:sendmessage(hwnd,WM_CopyData,0,cardinal(@cds));
if wmCopyData.CopyDataStruct^.cbData = sizeof(TMydata) then
CopyMemory(@myData,@lParam,sizeof(TMyData));
end;
else Result:=DefWindowProc(hwnd, message,wParam, lParam);
end;
end;
próbowałem na wszystkie sposoby jakie znam i jake udało mi sie znalesc na necie ale nic niedaje prosze jakąś pomoć