>>>Is it possible?? If so, how should look the target line in a shortcut?
>>>
>>Yes,
>>Target line would be like any other parameter line. But from VFP side you get only one string parameter (containing whole parameter line) and parse it as appropriate.
>
>Hi Cetin, could you give me an example? I´ve been playing with this and I always get a vfp error... Don´t know what I am doing wrong. I think everything is right by the vfp side: I need only one parameter which is received in the main prg.
Hi Renato,
First a correction to my previous reply. Now with VFP parameters are parsed as spaces encountered on parameter line automatically and you have true parameters() count. Below is an example :
* VFP main - vfpparamtest.exe
parameters m1,m2,m3
? parameters()
? type("m1"),m1
? type("m2"),m2
? type("m3"),m3
* Calling line (shortcut): vfpparamtest.exe 5 .t. test
* Equivalant inside VFP calling vfpparamtest("5",".t.","test")
* Output
3
C 5
C .t.
C test
Now something you should be aware of is all passed parameters are CHAR type. If your program waits something different ie: numeric you must convert it :
parameters gnLoopCount
gnLoopCount = val(gnLoopCount)
Cetin