VB.NET Get command line arguments

I would like to keep track this link on my blog because I searched it a lot of time and I lost it everytime
The GetCommandLineArgs Method is used to retrieve arguments (parameters) from a console application based on .NET Frameworks.

Just a small sample:
Public Shared Sub Main()
Console.WriteLine()
' Invoke this sample with an arbitrary set of command line arguments.
Dim arguments As [String]() = Environment.GetCommandLineArgs()
Console.WriteLine("GetCommandLineArgs: {0}", [String].Join(", ", arguments))
End Sub 'Main

Share on Google Plus

About Vittorio Pavesi

    Blogger Comment
    Facebook Comment

1 commenti:

Anonymous said...

Totally useful and to the point. Glad it showed up early in the search results. Thanks.