Hi Alan,
I'd check to make sure the program is available to your calling program. I just ran the following code from the command window with no problem in VFP8.
?XYZ(1)
Returns 10.
XYZ.PRG:
LPARAMETERS tnNumber
RETURN tnNumber * 10
HTH,
>I'm attempting to convert a vfp5 executable into vfp8.
>
>xyz is a prg that is included in the project. It accepts a numeric parameter and returns a value. In vfp5, I call it like this:
>
>lnValue = xyz(1)
>
>In vfp8, I get an error, "invalid subscript reference" - apparently vfp8 thinks xyz is an array and does not recognize it as a prg. Is there a way to let vfp8 know that this is a prg and not an array?
>
>Thanks,
>Alan
Jim