forum.vdsworld.com Forum Index forum.vdsworld.com
Visit VDSWORLD.com
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


Pass info to VDS Program when run...

 
Post new topic   Reply to topic    forum.vdsworld.com Forum Index -> General Help
View previous topic :: View next topic  
Author Message
MarkTrubo
Contributor
Contributor


Joined: 27 May 2001
Posts: 148
Location: Long Island, NY

PostPosted: Sat Dec 17, 2005 11:12 pm    Post subject: Pass info to VDS Program when run... Reply with quote

Can I pass some info to a VDS program when launching it, like a command line opiton or something in the shell command? If so, how do I capture that info? I'm using VDS4.
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger
MarkTrubo
Contributor
Contributor


Joined: 27 May 2001
Posts: 148
Location: Long Island, NY

PostPosted: Sat Dec 17, 2005 11:24 pm    Post subject: Reply with quote

Never mind! I found the answer here:

http://forum.vdsworld.com/viewtopic.php?t=177&highlight=pass+command+line+parameters
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger
Hooligan
VDS Developer
VDS Developer


Joined: 28 Oct 2003
Posts: 480
Location: California

PostPosted: Sat Dec 17, 2005 11:29 pm    Post subject: Reply with quote

Hi Mark,

Any switches passed into the program can be read with %1 thru %9. for instance:

test.exe /opt1 /opt2

%1 will be equal to "opt1" and %2 will be equal to "opt2".

Good luck,

Hooligan

_________________
Hooligan

Why be normal?
Back to top
View user's profile Send private message
MarkTrubo
Contributor
Contributor


Joined: 27 May 2001
Posts: 148
Location: Long Island, NY

PostPosted: Sun Dec 18, 2005 1:10 am    Post subject: Reply with quote

Funny, but with the hundreds of VDS programs I've written over the years, I never really needed this until today.

Most of the time I needed to pass complicated stuff, so I always just wrote it to a file which I then read with the next program. For today's issue, that was not practical. I'm passing callerid to a customer order look-up program.

thanks gang!
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger
Display posts from previous:   
Post new topic   Reply to topic    forum.vdsworld.com Forum Index -> General Help All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum

Twitter@vdsworld       RSS

Powered by phpBB © 2001, 2005 phpBB Group