|
web
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
How to pass parameter?Hi
I want to call an application and also need to pass some parameter for it. I use System.Diagnostics.Process.Start("application_path") and it runs perfectly. But when I pass paramenter like System.Diagnostics.Process.Start("application_path -parameter1 -parameter2") it says that the file doesn't exist. How should I pass parameter? Thanks Hi
For starting a process with command line arguments you can use other overloads of Process Class : Process.Start(fileName, arguments) So : System.Diagnostics.Process.Start("application_path ","-parameter1 -parameter2") Or you can use Process.StartInfo.Arguments . I hope this helps A.Hadi Hi,
Thanks it worked fined. How would I kill the started process? Bye Mukesh Show quoteHide quote "Aboulfazl Hadi" <AHa***@gmail.com> wrote in message news:1141365012.142878.250330@i39g2000cwa.googlegroups.com... > Hi > For starting a process with command line arguments you can use other > overloads of Process Class : > > Process.Start(fileName, arguments) > So : > > System.Diagnostics.Process.Start("application_path ","-parameter1 > -parameter2") > > > Or you can use Process.StartInfo.Arguments . > > I hope this helps > A.Hadi > "Chakravarti Mukesh" <cmuk***@sparshindia.com> schrieb: \\\> How would I kill the started process? Dim p As Process = Process.Start(...) .... ' Better: 'CloseMainWindow' for applications which have a ' main window. p.Kill() /// -- M S Herfried K. Wagner M V P <URL:http://dotnet.mvps.org/> V B <URL:http://classicvb.org/petition/>
Show quote
Hide quote
"Chakravarti Mukesh" <cmuk***@sparshindia.com> wrote in message System.Diagnostics.Process.Start("application_path" -parameter1 -parameter2)news:eXsbPOoPGHA.964@tk2msftngp13.phx.gbl... > Hi > I want to call an application and also need to pass some parameter for it. > I use > System.Diagnostics.Process.Start("application_path") > > and it runs perfectly. But when I pass paramenter like > > System.Diagnostics.Process.Start("application_path -parameter1 -parameter2") > > it says that the file doesn't exist. How should I pass parameter? > > Thanks
Pulling specific words from a string
Basic question Enumerate members of Administrators Group (AD) MenuItem.RadioCheck Radio Button Grouping in vb/VS 2005 update more than only the email with asp.net membership Web service question Change Report Connection at Runtime Data Relation Update Namespace Question ... |
|||||||||||||||||||||||