VB.NET read standard output -


from application need run command , parse output. can no problem don't want command displayed. hoped windowstyle = processwindowstyle.hidden work doesn't. take sample code below example. works fine command window still visibly opens , closes , need never show ugly face. how can fix this?

dim myprocess new process dim lines string = ""  myprocess     .startinfo.filename = "c:\windows\system32\cmd.exe"     .startinfo.arguments = "/c ipconfig"     .startinfo.windowstyle = processwindowstyle.hidden     .startinfo.redirectstandardoutput = true     .startinfo.useshellexecute = false     .start() end  lines = myprocess.standardoutput.readtoend  msgbox(lines) 

try setting createnowindow true too.

if trying achieve find ip address(es) of local machine, there more direct ways of doing it.


Comments

Popular posts from this blog

c# - SharpSVN - How to get the previous revision? -

c++ - Is it possible to compile a VST on linux? -

url - Querystring manipulation of email Address in PHP -