| View previous topic :: View next topic |
| Author |
Message |
LinkSisco Valued Newbie
Joined: 17 May 2002 Posts: 30 Location: UK
|
Posted: Fri Jun 28, 2002 7:19 pm Post subject: Only reading from part of an input, help |
|
|
Ok, say i have an exe that runs from switchs...
and i enter into the cmd prompt "exename.exe word:something"
how could i get my program to remove the word: leaving just something?
ps im using vds 3...
Thanks. |
|
| Back to top |
|
 |
SnarlingSheep Professional Member


Joined: 13 Mar 2001 Posts: 759 Location: Michigan
|
Posted: Fri Jun 28, 2002 7:56 pm Post subject: |
|
|
Well if the input will always be "word:something" then you can remove word: from %1.
| Code: |
REM %1 holds word:something
%%Word = @SUBSTR(%1,6,@LEN(%1))
REM %%Word will now hold everything after word:, which is "something"
info %%Word
|
Hope that makes sense. _________________ -Sheep
My pockets hurt... |
|
| Back to top |
|
 |
LinkSisco Valued Newbie
Joined: 17 May 2002 Posts: 30 Location: UK
|
Posted: Fri Jun 28, 2002 8:01 pm Post subject: |
|
|
| Perfect thank you. |
|
| Back to top |
|
 |
|