Welcome to Dream.In.Code
Getting VB Help is Easy!

Join 136,406 VB Programmers for FREE! Get instant access to thousands of VB experts, tutorials, code snippets, and more! There are 2,464 people online right now. Registration is fast and FREE... Join Now!




Executing with parameters

 
Reply to this topicStart new topic

Executing with parameters

rkapoor123
30 Aug, 2008 - 06:50 PM
Post #1

New D.I.C Head
*

Joined: 30 Aug, 2008
Posts: 1

I have an applicatoin and I have to change it to expect an external parameters from the OS. How do I pass this parameter...Thanks already
User is offlineProfile CardPM
+Quote Post

Ken Halter
RE: Executing With Parameters
31 Aug, 2008 - 09:43 AM
Post #2

New D.I.C Head
*

Joined: 18 Nov, 2007
Posts: 35



Thanked: 5 times
My Contributions
VB has an internal variable called Command$ that will hold any command line arguments sent to your app. It's entirely up to you to specify the "rules" and verify the syntax of any arguments sent.

To test your code, you can have VB send a command line every time you start your app...

To do that, click on the 'Project' menu, the last item should be <your project name> Properties. Click on that, then click on the 'Make' tab. Near the bottom, there's a textbox called "Command Line Arguments". That's where you can put your test command lines.

So, if you find that box and enter 'This is a Test' in the box and run this code, you should see a message box that says "This is a test"

Private Sub Form_Load()
MsgBox Command$
End Sub

User is offlineProfile CardPM
+Quote Post

Fast ReplyReply to this topicStart new topic
Time is now: 12/2/08 12:06PM

Live VB Help!

VB Tutorials

Reference Sheets

VB Snippets

DIC Chatroom

Bye Bye Ads

Monthly Drawing

Thumb Drive

Top Contributors

Top 10 Kudos This Month