Click here to Skip to main content
16,011,508 members
Home / Discussions / C#
   

C#

 
GeneralRe: Inter Process Communication Pin
gek_at13-May-04 8:18
gek_at13-May-04 8:18 
Questionhow do I marshal lpvoid pointer in a funcion? Pin
Paolo Ponzano13-May-04 2:24
Paolo Ponzano13-May-04 2:24 
AnswerRe: how do I marshal lpvoid pointer in a funcion? Pin
Heath Stewart13-May-04 3:29
protectorHeath Stewart13-May-04 3:29 
GeneralRe: how do I marshal lpvoid pointer in a funcion? Pin
Paolo Ponzano13-May-04 4:40
Paolo Ponzano13-May-04 4:40 
GeneralRe: how do I marshal lpvoid pointer in a funcion? Pin
Heath Stewart13-May-04 5:04
protectorHeath Stewart13-May-04 5:04 
GeneralRe: how do I marshal lpvoid pointer in a funcion? Pin
Paolo Ponzano13-May-04 5:27
Paolo Ponzano13-May-04 5:27 
GeneralRe: how do I marshal lpvoid pointer in a funcion? Pin
Heath Stewart13-May-04 6:21
protectorHeath Stewart13-May-04 6:21 
GeneralRe: how do I marshal lpvoid pointer in a funcion? Pin
Paolo Ponzano13-May-04 7:20
Paolo Ponzano13-May-04 7:20 
I've fixed it but the function ToolHelp32ReadMemory fails, I don't know why but I'll check later, here's my source if anyone of you see an error, please tell me

<br />
	[DllImport("toolhelp.dll")]<br />
		private static extern bool Toolhelp32ReadProcessMemory( <br />
											  IntPtr th32ProcessID,<br />
											  int lpBaseAddress, <br />
											  IntPtr lpBuffer,<br />
											  uint cbRead, <br />
											  IntPtr lpNumberOfBytesRead <br />
											  );<br />
		public static void DoDump(Process p)<br />
		{<br />
			<br />
			try<br />
			{<br />
								byte[] databuffer = new byte[120];<br />
				uint byteread=0;<br />
				GCHandle br= GCHandle.Alloc(byteread);<br />
								GCHandle handle = GCHandle.Alloc(databuffer);<br />
								IntPtr ptr =(IntPtr)handle;<br />
			<br />
			if((Toolhelp32ReadProcessMemory(p.Handle,p.BaseAddess,(IntPtr)handle,120,(IntPtr)br)== false))<br />


I can't even see disassembly on PocketPC, but p.Handle and p.BaseAddress seems ok
thanks
Paolo
GeneralRe: how do I marshal lpvoid pointer in a funcion? Pin
Heath Stewart13-May-04 9:37
protectorHeath Stewart13-May-04 9:37 
GeneralRe: how do I marshal lpvoid pointer in a funcion? Pin
Paolo Ponzano13-May-04 11:43
Paolo Ponzano13-May-04 11:43 
GeneralRe: how do I marshal lpvoid pointer in a funcion? Pin
Heath Stewart13-May-04 12:36
protectorHeath Stewart13-May-04 12:36 
GeneralRe: how do I marshal lpvoid pointer in a funcion? Pin
Paolo Ponzano13-May-04 20:18
Paolo Ponzano13-May-04 20:18 
GeneralRe: how do I marshal lpvoid pointer in a funcion? Pin
Heath Stewart14-May-04 2:16
protectorHeath Stewart14-May-04 2:16 
GeneralUserControl and how to add controls to it Pin
Boaz V13-May-04 1:24
Boaz V13-May-04 1:24 
GeneralRe: UserControl and how to add controls to it Pin
Boaz V13-May-04 1:34
Boaz V13-May-04 1:34 
GeneralRe: UserControl and how to add controls to it Pin
Boaz V13-May-04 2:09
Boaz V13-May-04 2:09 
GeneralRe: UserControl and how to add controls to it Pin
sreejith ss nair13-May-04 2:50
sreejith ss nair13-May-04 2:50 
GeneralRe: UserControl and how to add controls to it Pin
Heath Stewart13-May-04 3:38
protectorHeath Stewart13-May-04 3:38 
GeneralRe: UserControl and how to add controls to it Pin
Boaz V13-May-04 3:48
Boaz V13-May-04 3:48 
GeneralCreating Installation Package for a C# Application with web reference Pin
koosala13-May-04 1:22
koosala13-May-04 1:22 
GeneralRe: Creating Installation Package for a C# Application with web reference Pin
Aryadip13-May-04 1:49
Aryadip13-May-04 1:49 
GeneralRe: Creating Installation Package for a C# Application with web reference Pin
koosala14-May-04 0:31
koosala14-May-04 0:31 
GeneralRe: Creating Installation Package for a C# Application with web reference Pin
Heath Stewart13-May-04 2:00
protectorHeath Stewart13-May-04 2:00 
GeneralRe: Creating Installation Package for a C# Application with web reference Pin
Anonymous18-May-04 4:35
Anonymous18-May-04 4:35 
GeneralThread problem Pin
michael.wikstrom13-May-04 1:08
michael.wikstrom13-May-04 1: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.