Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Starting exe from another exe
Message
De
11/06/2008 10:43:50
 
 
À
11/06/2008 02:49:23
Information générale
Forum:
ASP.NET
Catégorie:
Autre
Versions des environnements
Environment:
C# 3.0
Divers
Thread ID:
01322835
Message ID:
01323094
Vues:
22
Stuart,

Use the code I showed for your static void Main. Pass the parameters as one string. The
string[] args
will be "parsed" with space delimiters. So, if you call it with:
System.Diagnostics.Process.Start("My.exe", "one 2 three 4");
Your My.exe application will detect that as being 4 parameters. In other words, args.Length will = 4.

~~Bonnie




>Hi
>I still just do not understand this, the System.Diagnostics.Process.Start insisted on a string and the main insists on an array,I can think
>Of a few ways to program around this, but I assume there must be reason its like this and a proper way to do this?
>Any help gratefully recieved
>Thanks
>Stuart
Bonnie Berent DeWitt
NET/C# MVP since 2003

http://geek-goddess-bonnie.blogspot.com
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform