>CREATE CURSOR myCursor ( myField I) >USE DBF() IN 0 ALIAS (myProc(1)) AGAIN && <== ERROR >USE > >PROCEDURE myProc > RETURN 'myAlias' >ENDPROC >hi Fabio,
aa='123' ?type[[aa]] ?type['aa'] ?type('aa') ?type[[aa] && error : 'Function name is missing )' (not ])If the function is an internal function, it knows it is a function.
CREATE CURSOR myCursor ( myField I) use DBF('myCursor') again in 0 alias (juststem(dbf('myCursor'))+'_')In the context below, it also tests for an array. If the array exists, it is used
public myProc[2] myProc[1] = 'array' ?MyProc[1] && array release MyProc ?MyProc[1] && function ?MyProc2(1) && error : file MyProc2.prg does not exist function Myproc(xx) return 'function' endfuncIn a nutshell
do case case internal function use it case array defined use it case ??? (for some commands) throw an error case function defined use it otherwise throw an error endcase