Functions rock.

They fit happily as I-types subs() too.



SUBR('addThese',SUB.TOTAL,TAX)



One weirdism is that if you have internal subroutines you need to use
return(x) syntax. I usually use return(@null) to indicate that it's not
used.



function addThese(a,b)

  gosub MySub:

return(ans)

MySub:

  ans = a + b

return(@null)

The:end



per-functionally,

Stuart



-----Original Message-----

As I understand it, the return value is an "invisible" parameter in the

parameter list.



You can still pass other values back through the parameter list like you do


with CALLed subroutines.



I use it for if foo() then ... else...

Eg: if OpenFile(DICT,FILENAME,FILEHANDLE) then























































































































































































































































































































































































































































































































































































































































































































































**********************************************************************
This email message and any files transmitted with it are confidential
and intended solely for the use of addressed recipient(s). If you have 
received this email in error please notify the Spotless IS Support Centre (61 3 
9269 7555) immediately who will advise further action.

This footnote also confirms that this email message has been scanned
for the presence of computer viruses.
**********************************************************************
-------
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/

Reply via email to