Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Pass parameter to an exe file
Message
From
25/04/2002 06:07:20
 
 
To
25/04/2002 04:57:51
Denis Filer
University of Oxford
United Kingdom
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00649023
Message ID:
00649032
Views:
18
Denis,
Yes you can pass parameters to an EXE file. There are a few things you have to consider:

- The first line of your main program must start with a PARAMETER statement
- Parameters passed to an exe are passed as character type. If you need different types, then you have to parse/convert the parameter
- Omitted parameters are passed as .F.
- Multiple parameters are seperated with a space

So you could call your exe like this:
MyPrg.exe DenisFiler
HTH
>I want to call my VFP myprg.exe file and pass a character parameter (a users name) to streamline logging in. It works fine when in Fox using "do myprg with 'username'". Can this be done on a desktop shortcut? Thanks in advance. I should know this...
Daniel
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform