
Using mdb reference is allowed only from mdb file
r2d2,
Quote:
> I have reference from my Project1.mdb file to another CommonLib.mdb file.
> If I try to compile Project1.mdb file into mde, it show error.
> If I compile CommonLib.mdb into mde and then reference mde from
> Project1.mdb, then will be able to compile Project1.mdb
> Why is that happening ?
This is by design and is meant to insure the security of your code. As you
may know, creating an MDE strips out the code and replaces it with compiled
VBA pseudocode. As a result, the user cannot view the code and shouldn't be
able to do so in any of the project's libraries either. Once a file is
compiled into an mde, neither it nor it's libraries can be changed or the
app will fail to run any code. To minimize the chances that someone may
change things in your library db, they made it possible only to reference
other mdes from mde file.
Quote:
>Does compilation process compile data from all referenced libraries into
> current project (which will allow me to delete referenced mde at runtime)
?
I don't think it compiles all the code from the library db into the current,
but it definitely knows more about the lib than it's path because you cannot
replace a library db with an updated one (even with the same name and path)
without recreating your current project mde file. You cannot delete the
referenced db at runtime.
HTH,
Josh
Quote:
> I have reference from my Project1.mdb file to another CommonLib.mdb file.
> If I try to compile Project1.mdb file into mde, it show error.
> If I compile CommonLib.mdb into mde and then reference mde from
> Project1.mdb, then will be able to compile Project1.mdb
> Why is that happening ?
> Does compilation process compile data from all referenced libraries into
> current project (which will allow me to delete referenced mde at runtime)
?