[Gambas-user] static functions in libraries?
Rob
sourceforge-raindog2 at ...94...
Fri Nov 7 20:45:35 CET 2003
OK, so I actually tried to use my shiny new library in a project,
and after bashing my head against the wall because the IDE
didn't recognize the "Loan" class despite the presence of USE
"Finance" (with Finance in the same directory), I finally put
"Public Loan as Loan" at the top of the module and "Loan = NEW
Loan" in my sub after the USE, and then it complained because
the functions I wrote are static. But taking out the Loan = NEW
Loan caused the functions to die with "Null object" (which makes
sense.)
So is it not possible to put static subs and functions into a
library? Can I not just tell my users to USE "Finance" at the
start of their sub main and then use my static functions at
will? I'm trying to use the libraries to add functions they
think are lacking in Gambas, not create a "Loan object" or
whatever.
Rob
More information about the User
mailing list