No nothing special. This is how I use.
procedure StartApplication (sexe: string);
var
StartupInfo: TStartupInfo;
ProcessInfo: TProcessInformation;
begin
FillChar(StartupInfo, SizeOf(TStartupInfo), 0);
StartupInfo.cb := SizeOf(TStartupInfo);
if CreateProcess(Nil,PChar(sexe),nil, nil, False, NORMAL_PRIORITY_CLASS,
nil, Nil, StartupInfo, ProcessInfo) then
with ProcessInfo do begin
WaitForInputIdle(hProcess, INFINITE); // not sure why I put this line
here, you may not need it
CloseHandle(hThread);
CloseHandle(hProcess);
end;
end;
----- Original Message -----
From: "Mark Derricutt" <[EMAIL PROTECTED]>
To: "Multiple recipients of list delphi" <[EMAIL PROTECTED]>
Sent: Tuesday, 12 December 2000 8:39
Subject: Re: [DUG]: Dissapearing app...
> On Mon, 4 Dec 2000, Alex Kouznetsov wrote:
>
> > 3) Instead of ShellExecute try to use CreateProcess (with properly
released
> > process and thread handles immidiately after loading the application)
>
> Do you have any example code on using CreateProcess? The last time I was
> playing with that I could never actually get it working properly, is there
> anything special I need to do to pass params to this as well? I think
> that might be were part of the problem is...
>
> --
> "We don't guarantee anything except that it will take up disk space..."
> Apache 2.0alpha5 Disclaimer
>
> Now Playing: Rob Halford - Saviour
>
> --------------------------------------------------------------------------
-
> New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
> Website: http://www.delphi.org.nz
> To UnSub, send email to: [EMAIL PROTECTED]
> with body of "unsubscribe delphi"
>
---------------------------------------------------------------------------
New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
Website: http://www.delphi.org.nz
To UnSub, send email to: [EMAIL PROTECTED]
with body of "unsubscribe delphi"