Location of Functions and Called Subs

Creating a macro - Writing a Script - Using the API (OpenOffice Basic, Python, BeanShell, JavaScript)
Post Reply
rbenrey
Posts: 3
Joined: Sat Jun 28, 2008 5:01 pm

Location of Functions and Called Subs

Post by rbenrey »

Until recently, I've been placing functions and called subs in the the same module as the Sub doing the calling. Am I right in assuming they can be in any module in the same Library?

Thanks,

Ron
OOo 2.4.X on Ubuntu 8.x + Windows XP
QuazzieEvil
Volunteer
Posts: 283
Joined: Tue Dec 04, 2007 6:38 pm
Location: Houston, TX

Re: Location of Functions and Called Subs

Post by QuazzieEvil »

They can be placed in any module in any library.

To call a function in a differnet library, simply load the library first: BasicLibraries.loadLibrary("lib_name")

If you have funtions/subs with the same name in various mods/libs, you can call it view the module: Utils.createRowSet("DB2",0,"EMPLOYEES") would call the function createRowSet(...) which is in the module Utils.

--hope this helps.
Post Reply