Click here to Skip to main content
15,890,438 members
Home / Discussions / C#
   

C#

 
GeneralRe: Encrypting\Decrypting Pin
Julian Bucknall [MSFT]28-Jul-03 11:28
Julian Bucknall [MSFT]28-Jul-03 11:28 
GeneralRe: Encrypting\Decrypting Pin
draco_iii29-Jul-03 2:13
draco_iii29-Jul-03 2:13 
QuestionInstaller "Catch 22" with versioning? Pin
Arun Bhalla28-Jul-03 9:15
Arun Bhalla28-Jul-03 9:15 
GeneralIn Bitmap hell Pin
RB@Emphasys28-Jul-03 8:13
RB@Emphasys28-Jul-03 8:13 
GeneralRe: In Bitmap hell Pin
Not Active28-Jul-03 9:25
mentorNot Active28-Jul-03 9:25 
Questionhow to use SendMessage() from C#?? Pin
misterbear28-Jul-03 7:57
misterbear28-Jul-03 7:57 
AnswerI know one more thing... Pin
misterbear28-Jul-03 8:18
misterbear28-Jul-03 8:18 
GeneralRe: I know one more thing... Pin
J. Dunlap28-Jul-03 8:51
J. Dunlap28-Jul-03 8:51 
[DllImport("user32.dll", CharSet=CharSet.Auto)]
private extern static int SendMessage(IntPtr hwnd, int msg, int wParam, ref COPYDATASTRUCT lParam);
 
[StructLayout(LayoutKind.Sequential)]
struct COPYDATASTRUCT {  // cds 
    int dwData; 
    int cbData; 
    IntPtr lpData; 
}
 
//------Managed Way--------
 
//assume that the variable "data" holds the data
 
COPYDATASTRUCT cds=new COPYDATASTRUCT;
 
cds.cbData=Marshall.SizeOf(data);
IntPtr mem=Marshall.AllocHGlobal(cds.cbData);
cds.lpData=Marshall.StructureToPtr(data,mem,true);
cds.lpData=mem;
//now do the SendMessage call, then do cleanup of resources
 
//-----UnManaged Way------
 
[DllImport("user32.dll", CharSet=CharSet.Auto)]
private extern static int SendMessage(IntPtr hwnd, int msg, int wParam, void* lParam);
 
COPYDATASTRUCT cds=new COPYDATASTRUCT;
SendMessage(handle,WM_COPYDATA,wParam,(void*)&cds);
 



"Blessed are the peacemakers, for they shall be called sons of God." - Jesus

"You must be the change you wish to see in the world." - Mahatma Gandhi







GeneralRe: I know one more thing... Pin
misterbear28-Jul-03 10:35
misterbear28-Jul-03 10:35 
GeneralRe: I know one more thing... Pin
J. Dunlap28-Jul-03 10:43
J. Dunlap28-Jul-03 10:43 
GeneralRe: I know one more thing... Pin
Eric Gunnerson (msft)28-Jul-03 11:17
Eric Gunnerson (msft)28-Jul-03 11:17 
GeneralRe: I know one more thing... Pin
leppie28-Jul-03 11:15
leppie28-Jul-03 11:15 
GeneralRe: I know one more thing... Pin
J. Dunlap28-Jul-03 11:21
J. Dunlap28-Jul-03 11:21 
GeneralRe: I know one more thing... Pin
leppie28-Jul-03 11:27
leppie28-Jul-03 11:27 
GeneralHttpWebRequest Timeout Pin
albean28-Jul-03 5:13
albean28-Jul-03 5:13 
GeneralRe: HttpWebRequest Timeout Pin
Arun Bhalla28-Jul-03 5:35
Arun Bhalla28-Jul-03 5:35 
GeneralRe: HttpWebRequest Timeout Pin
albean28-Jul-03 6:08
albean28-Jul-03 6:08 
GeneralRe: HttpWebRequest Timeout Pin
Arun Bhalla28-Jul-03 6:11
Arun Bhalla28-Jul-03 6:11 
GeneralPallaControls and combobox Pin
totig28-Jul-03 2:38
totig28-Jul-03 2:38 
GeneralRe: PallaControls and combobox Pin
Alex Korchemniy28-Jul-03 4:03
Alex Korchemniy28-Jul-03 4:03 
GeneralRe: PallaControls and combobox Pin
totig28-Jul-03 4:37
totig28-Jul-03 4:37 
GeneralReducing color depth of an image in c# Pin
CyberKewl28-Jul-03 0:02
CyberKewl28-Jul-03 0:02 
GeneralRe: Reducing color depth of an image in c# Pin
J. Dunlap28-Jul-03 9:06
J. Dunlap28-Jul-03 9:06 
GeneralRe: Reducing color depth of an image in c# Pin
CyberKewl28-Jul-03 13:03
CyberKewl28-Jul-03 13:03 
GeneralRe: Reducing color depth of an image in c# Pin
J. Dunlap28-Jul-03 13:08
J. Dunlap28-Jul-03 13:08 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.