Microsoft Small Basic

Program Listing: MBD550
' If you start a Small Basic program from the command line, you can pass arguments to it.
' (Look for the .exe file in the same directory as the corresponding .sb file.)
TextWindow.WriteLine("Number of arguments is: " + Program.ArgumentCount + ".")
TextWindow.WriteLine("Program's directory is: " + Program.Directory + ".")
TextWindow.WriteLine("First argument is: " + Program.GetArgument(1) + ".")
Program.Delay(5000)
Program.End()