Hi Dmitry
Name the PRG the name of the function (MyProcedure.PRG). Don't put a function or procedure line. Start with an LPARAMETERS line.
Call the function with DO MyProcedure or with x=MyProcedure() and you save a line of code because you don't have to SET PROCEDURE TO. You also don't have to DO MyProcedure in MyProc.PRG. The MyProcedure.PRG must be in the path until compiled into an EXE or APP.
>>
>>The first parameter is passed in anyway as logical false (.F.) but yes, it's good way to pass only second parameter, assuming that the first one never can be false(.F.).
>
>Thank you, Sergey.
>This is exactly what I was doing. And I wanted to be sure that I was not breaking something that will bite me later. Eventually I will change all my procedures to declared procedures. That is, I want to have inside the .PRG file something like
>
>FUNCTION MyProcedure
>
>This way I can pass parameters a more flexibly, I think.