mwm@pa.dec.com (Mike (My Watch Has Windows) Meyer) (03/08/91)
[Note - I've crossposted this to comp.lang.rexx, and pointed followups there.] In article <1991Mar7.145635.22878@ux1.cso.uiuc.edu> jsivier@ux1.cso.uiuc.edu (Jonathon Sivier ) writes: > Does anyone know what the meaning of the error code > 20 is as returned from AmigaVisions AREXX port. Yes, finally a question I know the answer to. All the functions in ARexx return values, i.e. the open function returns a value indicating whether or not it was successful. If you don't assign that return value to a variable it gets sent to the currently set command address. There it is processed as a command and is probably garbage as far as the addressed process is concerned. The process returns a command failed return value of 20 which ARexx echoes to the screen telling you that this command you didn't intend to send has failed. If you make sure that all ARexx functions have their return values assigned to some variable, use something like DUMMY if you don't intend to use this value, then the problem will go away. Excellent analysis. Two tricks to make the life of a Rexx programmer easier, though: Use the CALL command instead of a dummy variable. You can replace "dummy = function(arg1, arg2)" with "call function arg1, arg2". This makes it obvious the return value is never used. These functions tend to return 0 or 1. Create two files "rexx:0" and "rexx:1", both being. /* */ say "Function return value invoked as command." exit 0 You might consider having it use the PARSE command to extract and print appropriate environmental information. <mike -- Love and affection, Mike Meyer Of the corporate kind. mwm@pa.dec.com It's just belly to belly, decwrl!mwm Never eye to eye.