K
koko
My Application is used by a large number of users on computers with different configurations. I am adding an export routine that uses a
DLL and which will be used by only a few of the users. The DLL may or may not be installed on a given PC.
I want to allow the export routine when the DLL is installed on a PC and to disallow it when the DLL is not installed.
My first solution was to add a reference to the DLL using Tools --> References..., and when the application was started, to check
whether the reference was broken or not, and to remove it if broken. This approach did not work - When I tested an .MDB, Access
tried to recompile when opened on a PC without the DLL. When I tested an MDE on a PC without the DLL, it opens without error, but
displays a #Name error on a particular form.
Secondly I tried adding a reference at runtime, but this requires knowing the exact path to the .DLL. I would prefer not to use API calls
as users can be running any version of Windows from 98 to XP which could mean writing different versions of the API calls. Of course, I
will use API calls if there is no other way.
I'm developing for Access 97, Access 2000/2002/2003 and Win98, ME, NT4, 2k, XP
Please suggest the best way to achieve what I need to do.
DLL and which will be used by only a few of the users. The DLL may or may not be installed on a given PC.
I want to allow the export routine when the DLL is installed on a PC and to disallow it when the DLL is not installed.
My first solution was to add a reference to the DLL using Tools --> References..., and when the application was started, to check
whether the reference was broken or not, and to remove it if broken. This approach did not work - When I tested an .MDB, Access
tried to recompile when opened on a PC without the DLL. When I tested an MDE on a PC without the DLL, it opens without error, but
displays a #Name error on a particular form.
Secondly I tried adding a reference at runtime, but this requires knowing the exact path to the .DLL. I would prefer not to use API calls
as users can be running any version of Windows from 98 to XP which could mean writing different versions of the API calls. Of course, I
will use API calls if there is no other way.
I'm developing for Access 97, Access 2000/2002/2003 and Win98, ME, NT4, 2k, XP
Please suggest the best way to achieve what I need to do.