|
-
Nov 4th, 2001, 07:38 AM
#1
Thread Starter
Lively Member
How to Get Command Line Parameters....
Hi Guys,
Is it Possible to get command line Parameters in VB, like in C/C++. If Possible then how can we read those Parameters. I need this very urgently. thnx for ur help.
Stop Piracy. Stop Using Microsoft.
-
Nov 4th, 2001, 09:08 AM
#2
Command$ returns the command line. It's a single string with all of the command line paramters in it.
-
Nov 4th, 2001, 12:00 PM
#3
If you need to use multiple command line arguments, then you can easily use the Split() function, e.g:
Code:
C:\> MyProgram.exe cmd1/cmd2/cmd3
In VB:
Code:
Dim sCommandLine() As String
sCommandLine = Split(Command$)
For I = 0 To UBound(sCommandLine)
MsgBox sCommandLine(I)
Next I
-
Nov 12th, 2009, 04:19 AM
#4
New Member
Re: How to Get Command Line Parameters....
Nice. Really this has helped me.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|