var
CmdLine:string;
st:TStartUpInfo;
pp:TProcessInformation;
begin
CmdLine:='C:\CreateProcessSample.exe';
FillChar(st, sizeof(st), #0);
with st do
begin
cb:=sizeof(st);
dwFlags:=STARTF_USESHOWWINDOW;
ptitle :=nil;
wShowWindow:=SW_SHOW;
end;
CreateProcess(nil, PChar(CmdLine),nil,nil,LongBool(0),0, nil, nil,st,pp);
WaitForSingleObject(pp.hProcess, INFINITE);
...
end;
阅读(748) | 评论(0) | 转发(0) |