Hi Guys,
I need to send a string from c# application to another c# Application.
On receiving application side the code i have is below.
Ideally i dont want to wait after extracting mystr for results to be returned, i just want it to act like PostMessage. The reason i cant use PostMessage is because it doesnt work with WM_COPYDATA. Please help guys!!!!!!!!!!! !
I need to send a string from c# application to another c# Application.
On receiving application side the code i have is below.
Code:
protected override void WndProc(ref Message m)
{
switch (m.Msg)
{
case (int)Msg.WM_USER:
break;
case (int)Msg.WM_COPYDATA:
COPYDATASTRUCT mystr = new COPYDATASTRUCT();
Type mytype = mystr.GetType();
mystr = (COPYDATASTRUCT) m.GetLParam(mytype);
//Here is where i want to do my processing but return the result
//to calling application.
break;
}
base.WndProc(ref m);
}
Ideally i dont want to wait after extracting mystr for results to be returned, i just want it to act like PostMessage. The reason i cant use PostMessage is because it doesnt work with WM_COPYDATA. Please help guys!!!!!!!!!!! !
Comment