FORMS statement error number -6208

Started by Mark W., November 08, 2013, 11:05:27 AM

Previous topic - Next topic

Mark W.

Quote from: Rene S. on November 08, 2013, 01:02:59 PM
>>Hi Rene, that didn't work.  Can I mail the source to you privately?  I don't want to post it on a public forum.

That's the idea.
Rene
OK, I'm a new to this forum.  Where do I get your email address?

Reuben B.

I've seen this error with FourGen style code where you have the same .4gl in two different directories.

Look at the value of $FGLLDPATH and check in each of these directories (and the current directory) for another instance of U_security.42m

If my hunch is right, if you have FGLLDPATH=/some_other_directory:dcs/UTIL.4gm you will find in some_other_directory another U_security.42m

Reuben

Product Consultant (Asia Pacific)
Developer Relations Manager (Worldwide)
Author of https://4js.com/ask-reuben
Contributor to https://github.com/FourjsGenero

Mark W.

Quote from: Reuben B. on November 09, 2013, 05:52:52 AM
I've seen this error with FourGen style code where you have the same .4gl in two different directories.

Look at the value of $FGLLDPATH and check in each of these directories (and the current directory) for another instance of U_security.42m

If my hunch is right, if you have FGLLDPATH=/some_other_directory:dcs/UTIL.4gm you will find in some_other_directory another U_security.42m

Reuben


Thanks for your reply.  There is only one instance of this module in the FGLLDPATH directories.

Mark W.

OK, I've found out what the problem was: the new module was not, for some reason, deployed to the modules directory, so the program was trying to run the old version.  I still have a question, however: should the error message not have been something along the lines of "Cannot find function xyz" instead of the cryptic message that "the module is already loaded."?

Rene S.

Hello,
your problem des not exist in recent versions of Genero.

This is the output of a simple test, covering your problem: the runtime calls f1() and loads m2. When calling f2() the runtime tries to load m2 again.
Code (#) Select

sh test.sh
+ fglrun -V
fglrun 2.02.20 build-966.107
Built Nov 12 2013 08:11:39
(c) 1989-2009 Four J's Development Tools
+ fglcomp m1
+ cp m2a.4gl m2.4gl
+ fglcomp m2
+ fglrun -l m1.42m m2.42m
+ fglrun m1
here: f1
here: f2
+ cp m2b.4gl m2.4gl
+ fglcomp m2
+ fglrun m1
here: f1
FORMS statement error number -6208.
Module 'm2': already loaded.


Now the same test with a recent version:
Code (#) Select

sh test.sh
+ fglrun -V
fglrun 2.50.00 build-2201
Genero virtual machine
Target linux

Four Js*
Licensed Materials - Property of Four Js
(c) Copyright Four Js 1995, 2012. All Rights Reserved.
* Trademark of Four Js Development Tools Europe Ltd
  in the United States and elsewhere
+ fglcomp m1
+ cp m2a.4gl m2.4gl
+ fglcomp m2
+ fglrun -l m1.42m m2.42m
+ fglrun m1
here: f1
here: f2
+ cp m2b.4gl m2.4gl
+ fglcomp m2
+ fglrun m1
here: f1
Program stopped at 'm1.4gl', line number 3.
FORMS statement error number -1338.
The function 'f2' has not been defined in any module in the program.


The error message should be enhanced anyway. The runtime should uses the (already existing) error 6207: The dynamic loaded module '%s' does not contain the function '%s'.

Rene