c# - Running process from hidden window -


i have faced strange problem when trying run process hidden window - process run runs in hidden process, doing wrong? want run child process not hidden.

process.start(path.gettemppath() + "cleanup.exe", path.getdirectoryname(application.startuppath); 

you can try creating object of process class below :

process objprocess = new process();             objprocess.startinfo.useshellexecute = false; objprocess.startinfo.redirectstandardoutput = true; objprocess.startinfo.createnowindow = true; objprocess.startinfo.windowstyle = processwindowstyle.hidden;  // passing batch file/exe name objprocess.startinfo.filename = string.format(strbatchfilename);  // passing argument objprocess.startinfo.arguments = string.format(strargument); try {  objprocess.start(); } catch {  throw new exception("batch file not found processing"); } 

Comments

Popular posts from this blog

Delphi XE2 Indy10 udp client-server interchange using SendBuffer-ReceiveBuffer -

Qt ActiveX WMI QAxBase::dynamicCallHelper: ItemIndex(int): No such property in -

Enable autocomplete or intellisense in Atom editor for PHP -