You can retrieve the program command line (which includes the executable file name) as a string, or get an array of strings, where each element is an item on the command string:
Code:
' the command line passed to this program...
MessageBox.Show(Environment.CommandLine)
' the list of all the command line arguments
' (first element is the executable name)...
Dim arg as String
For Each arg in Environment.GetCommandLineArgs
MessageBox.Show(arg)
Next
Answer courtesy of Francisco Balena, "Programming Microsoft Visual Basic .Net", who put it so well there was no point in paraphrasing!