Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
No PARAMETER statement is found
Message
De
05/05/1999 17:17:00
 
 
À
05/05/1999 16:00:25
Information générale
Forum:
Visual FoxPro
Catégorie:
The Mere Mortals Framework
Divers
Thread ID:
00214951
Message ID:
00215528
Vues:
41
>>Also, realize that this will only pick up the first parameter on the line; for example:
>>
>>MyApp Mary had a little lamb
>>
>>has 5(!) parameters. If you want to pass a complex parameter that may include separator characters, make certain to enclose it in quotes, ie:
>>
>>MyApp "Mary had a little lamb"
>>
>>Quote encapsulation can also be used to avoid VFP from stripping command elements prefixed with / or - from the parameter list.
>
>True...
>
>What I like to do with multiple parameters is still have one parameter line and have a delimiter that sperates the parameteres, a la web url... then, I parse the parmeters for the values with my chop() function... so, my command line would look like...
>
>MyApp.Exe Mary~Had~A~Little~Lamb
>
>or
>
>MyApp.EXE Mary|Had|A|Little|Lamb...
>
>The tilde and pipe seem to work well, since they don't genrally apper in text or command line delimiters.
>

That wonder, until you need to specify a path on the command line that contains embedded spaces or your sep character (especially the tilde, which is often used in the short name derived from a long file name.) Quote encapsulation works there unambiguously.

>BOb
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform