Hi iyarosh,
I believe Fox can return values, if that is what you are looking for.
Note: Execution code is different from values returned.
For example.. in your main.prg as the last statement before doing a QUIT.. i suggect dont use QUIT but instead use.. RETURN gcReturnValue
Make sure gcReturnValue variable is available at the place where VFP exits. Probably, you declare that PUBLIC so that wherever you set its value within the application, it is available at the RETURN place.
If you are using a single form as your main form, you should declare PUBLIC gcReturnValue in your Init of form and in the form somewhere, the value gets assigned and in the unload event of the form..
RETURN gcReturnValue
(Instead of public, you can make that a form variable also)
But having main form cannot return an application value back. It will only retunr .T. as the value returned.
SO the way to get this done is... start a Main.PRG in the application. make the PRG as the main in the exeutable.
Add the code in the main.prg
DO FORM myFORM TO myRet
RETURN myRet
Then compile and test. The VFP execuatable will return the value correctly.
How do you receive the value in the DOS is a different story.
____________________________________________
ramani - (Subramanian.G) 