?
Solved

Command Line Arguments passed to VB.NET exe

Posted on 2003-10-27
3
Medium Priority
?
1,909 Views
Last Modified: 2008-03-17
Does anyone know where to pull command line arguments passed to a vb.net exe. The documentation says these are accessbile via the StartArguments Property. But I can't figure out how to access this. Any clues?

0
Comment
Question by:boneal06
3 Comments
 
LVL 44

Accepted Solution

by:
bruintje earned 1000 total points
ID: 9628430
you could have a look at

http://www.devx.com/dotnet/Article/10115
0
 
LVL 28

Expert Comment

by:iboutchkine
ID: 9628470
Imagine that you start the exe with params like that

abc.exe "param"


Dim args() As String
        Dim param() As String

        args = Split(CommandLine, """") 'split by quotation mark
now your param is in the last memeber of args array
        param = Trim(args(UBound(args)))
0
 
LVL 96

Expert Comment

by:Bob Learned
ID: 9628524
You can use the Environment.GetCommandLineArgs method.
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A basic question.. “What is the Garbage Collector?” The usual answer given back: “Garbage collector is a background thread run by the CLR for freeing up the memory space used by the objects which are no longer used by the program.” I wondered …
It seems a simple enough task, yet I see repeated questions asking how to do it: how to pass data between two forms. In this article, I will show you the different mechanisms available for you to do just that. This article is directed towards the .N…
Look below the covers at a subform control , and the form that is inside it. Explore properties and see how easy it is to aggregate, get statistics, and synchronize results for your data. A Microsoft Access subform is used to show relevant calcul…
With just a little bit of  SQL and VBA, many doors open to cool things like synchronize a list box to display data relevant to other information on a form.  If you have never written code or looked at an SQL statement before, no problem! ...  give i…
Suggested Courses
Course of the Month16 days, 14 hours left to enroll

864 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question