Posted on 2002-03-26
I actually develop in BCB4, but I think the issues are the same as they would be in Delphi. So here goes...
In an attempt to modularize our application, we're trying to build individual packages for different components of the program. I currently have a calling application that consists only of a MDI parent form, and a base TMainMenu. I also have a package that contiains a TMainMenu that merges with the parent, as well as a couple of MDI child forms. There is another package that is intended to hold only a class that will provide access to a set of static variables(ApplicationDBPointer/SessionPointer, LogonID and other such things).
The problem I'm encountering is that much of the code our objects are built with relies on a .LIB that our company has been using and building for years. The only way that I've successfully been able to build these packages is to include this .LIB in the project. When I do this, I get a
runtime error when trying to load a second package from the calling application (using LoadPackage( )). It's telling me that it can't load the second package because the first (loaded) package already contains one of
the units from the .LIB.
Unloading the frist package before loading the second is not really an option.
My guess is that I have a setting(s) wrong somewhere.
I'd really appreciate any information that could point me in the right direction.