Page 1 of 1

Rexx RXMath Libary - problems with loading it

PostPosted: Tue Dec 20, 2011 2:15 pm
by Eidmantas
I've been doing a simple job for my lectures, it worked fined yesterday at my home PC, but now in the class, or my laptop the rxmath libary does something strange. I'm using the newest ooRexx. I found some manuals that encouraged me to change to ::requires, but it still doesn't function properly. Drops out an error:

E:\galdarbas>rexx nd2.cmd
Error 20 running "E:\galdarbas\nd2.cmd", line 43: Name expected
Error 20.1: Name required; found ":" // this shows to the ::require ..... //

call rxfuncadd "MathLoadFuncs", "rxmath", "MathLoadFuncs"
d=((b*b)-(4*a*c))
saknis=RxCalcSqrt(d)
::requires 'rxmath' LIBRARY

B,A,C are pulled before. Windows PATH is set to the current directory(it has rxmath.dll) and to orexx also has the DLLs.

The whole script is here:
http://pastebin.com/aPzCPqzP

Thank you.

Re: Rexx RXMath Libary - problems with loading it

PostPosted: Tue Dec 20, 2011 2:21 pm
by NicC
None of this relates to mainframe Rexx. Go to a PC Rexx forum. For what it is worth - although you have added the math library you have not loaded the functions you want to use. I do not know if the requires directive does that behind the scenes.

Re: Rexx RXMath Libary - problems with loading it

PostPosted: Tue Dec 20, 2011 2:31 pm
by enrico-sorichetti
no need for the rxfuncadd stuff the ::requires directive takes care of it all.

#! /usr/bin/rexx
say "hallo from math.rx"
n = 4
say n rxcalcsqrt(n)
::requires "rxmath" LIBRARY


works for me...

but You must make sure that ooRexx has been properly installed, and/or
also look at the ooRexx docs on how to set the proper environment variables for non standard search paths