easy delphi declartion question..
-
- Posts: 87
- Joined: Thu Jun 02, 2005 3:46 am
easy delphi declartion question..
When using madshi SendIpcMessage getting this.
[Error] HookProcessCreation.dpr(159): E2029 ';' expected but '.' found
[Error] HookProcessCreation.dpr(161): E2029 Declaration expected but end of file found
in a blank vcl win32 form application... the declare statement
function SendIpcMessage(ipc : pchar;
messageBuf : pointer;
messageLen : dword;
answerBuf : pointer = nil;
answerLen : dword = 0;
answerTimeOut : dword = INFINITE;
handleMessages : bool = true ) : bool; stdcall;
is causing the end. error
Should be an easy one...new to delphi 05
[Error] HookProcessCreation.dpr(159): E2029 ';' expected but '.' found
[Error] HookProcessCreation.dpr(161): E2029 Declaration expected but end of file found
in a blank vcl win32 form application... the declare statement
function SendIpcMessage(ipc : pchar;
messageBuf : pointer;
messageLen : dword;
answerBuf : pointer = nil;
answerLen : dword = 0;
answerTimeOut : dword = INFINITE;
handleMessages : bool = true ) : bool; stdcall;
is causing the end. error
Should be an easy one...new to delphi 05
-
- Posts: 87
- Joined: Thu Jun 02, 2005 3:46 am
I am using this to define I believe..
This is being used inside of hookcreateprocess
function SendIpcMessage(ipc : pchar;
messageBuf : pointer;
messageLen : dword;
answerBuf : pointer = nil;
answerLen : dword = 0;
answerTimeOut : dword = INFINITE;
handleMessages : bool = true ) : bool; stdcall;
Can I just use without doing any other adding or declaring? If so thats what I need to do! I have put the askapplication call right where hookprocess messagebox's new process created, without the declare...the dll compiles and injects fine but I am not recieving any IPC messages when processes are created. Same IPC pipe name on both sides. Is there a way to trace ipc to see if the dll is sending anything at all? Thanks for you help
function AskApplication(question: string) : boolean;
begin
result := false;
SendIpcMessage('JustAnExample', pchar(question), Length(question), @result, sizeOf(result));
end;
This is being used inside of hookcreateprocess
function SendIpcMessage(ipc : pchar;
messageBuf : pointer;
messageLen : dword;
answerBuf : pointer = nil;
answerLen : dword = 0;
answerTimeOut : dword = INFINITE;
handleMessages : bool = true ) : bool; stdcall;
Can I just use without doing any other adding or declaring? If so thats what I need to do! I have put the askapplication call right where hookprocess messagebox's new process created, without the declare...the dll compiles and injects fine but I am not recieving any IPC messages when processes are created. Same IPC pipe name on both sides. Is there a way to trace ipc to see if the dll is sending anything at all? Thanks for you help
function AskApplication(question: string) : boolean;
begin
result := false;
SendIpcMessage('JustAnExample', pchar(question), Length(question), @result, sizeOf(result));
end;
Of course!bluedragon99 wrote:Can I just use without doing any other adding or declaring?
How does the app code look like?bluedragon99 wrote:I have put the askapplication call right where hookprocess messagebox's new process created, without the declare...the dll compiles and injects fine but I am not recieving any IPC messages when processes are created. Same IPC pipe name on both sides. Is there a way to trace ipc to see if the dll is sending anything at all?
You might want to check out the HookProcessTermination demo. It contains IPC sending.
-
- Posts: 87
- Joined: Thu Jun 02, 2005 3:46 am
-
- Posts: 87
- Joined: Thu Jun 02, 2005 3:46 am