PermaLink LotusScript dynamic class loading error resolved04/12/2007 04:20 PM
LotusScript
I've been using the dynamic class loading technique popularized by Bill Buchan since June '06. (If you're unfamiliar with dynamic class loading, I gladly refer you to Bill's BP312 Object Orientated LotusScript Techniques and Tricks presentation.) I've been extremely happy with the results with one exception. One database I've been developing off-and-on for the past year seems to have a problem with the classes I load dynamically in my agents. Whenever I change the classes, the agents that instantiate objects based on the classes return the following error:

$EXECUTE$+4: Class or type name not found: REQUESTFACTORY

Before I continue, I should state that LND 6.5.4 is being run on all Notes clients and Domino servers where I work. Yes, I deserve much pity and envy all of you who are using LND 7!!!

I tried re-saving the script libraries and then re-saving the agents that used the script libraries, and vice versa. The only way the error went away was when the server was rebooted. After the reboot, my agents were able to dynamically load the classes without a problem.

Since this project was put on hold since last September, I forgot all about this problem. Until today, that is.

Over the past several weeks, I've been testing the application and cleaning up the code when necessary. Lo and behold, the above error reared its ugly head again. I tried re-saving the script libraries and agents again, to no avail. Just as I was about to ask the Domino administrator to reboot the server, I decided to take another look at the script libraries containing the custom classes. And I had one of those epiphany moments that make you want to get up and leave work immediately, because the rest of the day just couldn't possibly get any better!

As I opened each of the eleven script libraries that contained custom classes, I noticed that three of them prompted me to save them when I closed them, even if I didn't touch the code at all. It turned out that for each of the these three script libraries, I'd added a comment to the script library's properties, like this:

script library properties

On a hunch, I removed the comments from these script libraries and re-saved them. I retried my agents and the error was gone. Whoo-hoo! Talk about a Notes quirk!!!
Comments :v

1. michael sobczak04/24/2007 03:12:05 AM


i am your doppleganger




2. Wild Bill05/06/2007 06:00:50 PM
Homepage: http://www.billbuchan.com


yeah - we tend to have to use "recompile all lotusscript" on databases - we have about 9 levels of inheritance going on, as well as dynamic loading. Anything new on the agents in terms of class signature, and its safer to recompile all..

---* Bill




Credits
NuTechs Powered by Domino
Search
Calendar
February 2012
Su
Mo
Tu
We
Th
Fr
Sa
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
Monthly Archive
Get Real, Detroit!
Real Detroit Weekly
SWARM
Service
With
A
Rapid
Motion


-- old Rally's Hamburgers credo
Lotus Domino ND6 RSS News Feed RSS Comments Feed Podcast Feed Geo URL netcraft RSS Validator Lotus Geek Chris. A. Brandlehner Open Notes Picture Database OpenNTF CoComment Integrated BlogSphere
By Category
The BlogRoll
About
Contact Me
Contact me, Michael Sobczak, using this e-mail address:

my first initial my last name at Yahoo dot com
Recent Entries
No Recent Blogs
Powered by
Blogsphere