Adlerm
asked on
Missing DLL in Access 2010
Can anyone tell me how to identify the name of a missing DLL in Access 2010.
The Access 2010 application I'm running is loaded onto the local C drive of about 10 PCs (Access 2010 frontend database on local PC C drive links to an Access 2010 backend database - tables only - on a shared drive) and works on all PCs except one.
The PC that is causing me trouble throws an error that a DLL is missing but doesn't identify which one.
I have identified where in the code the error message is thrown - see below for a extract of the code
Function MakeMergeText(frmF As Form, strOutFile As String) As Boolean
' build our merge file, and write a simple "csv" file to disk
Dim OneField As DAO.Field
Dim strFields As String
Dim strData As String
Dim intFile As Integer
Dim vField As Control
Dim t As Variant
If frmF.RecordSource <> "" Then
If frmF.RecordsetClone.Fields .Count > 0 Then <====== Error thrown when application tries to execute this line of code
I checked the Library references after copying the Access 2010 frontend database onto the local PC C drive and none are missing.
I suspect the DLL causing the error is either missing or the DLL register is corrupted but I can't find any way to identify the name of the DLL that is causing me grief. I could download some third party software (eg CureReg etc) but that doesn't guarantee me that it will fix my problem.
Any suggestion(s) would be greatly appreciated.
Many Thanks
Michael Adler
The Access 2010 application I'm running is loaded onto the local C drive of about 10 PCs (Access 2010 frontend database on local PC C drive links to an Access 2010 backend database - tables only - on a shared drive) and works on all PCs except one.
The PC that is causing me trouble throws an error that a DLL is missing but doesn't identify which one.
I have identified where in the code the error message is thrown - see below for a extract of the code
Function MakeMergeText(frmF As Form, strOutFile As String) As Boolean
' build our merge file, and write a simple "csv" file to disk
Dim OneField As DAO.Field
Dim strFields As String
Dim strData As String
Dim intFile As Integer
Dim vField As Control
Dim t As Variant
If frmF.RecordSource <> "" Then
If frmF.RecordsetClone.Fields
I checked the Library references after copying the Access 2010 frontend database onto the local PC C drive and none are missing.
I suspect the DLL causing the error is either missing or the DLL register is corrupted but I can't find any way to identify the name of the DLL that is causing me grief. I could download some third party software (eg CureReg etc) but that doesn't guarantee me that it will fix my problem.
Any suggestion(s) would be greatly appreciated.
Many Thanks
Michael Adler
I seriously doubt you actually wish to count the fields. There will always be at least one field, so ...
So try:
So try:
Dim rs As DAO.Recordset
Set rs = frmF.RecordsetClone
If rs.RecordCount > 0 Then
' do stuff.
End If
Set rs = Nothing
/gustav
More likely you have a missing reference on the end user machine. Can you list the references you have in the Access application? You can do that by opening the VBA Editor, then click Tools >> References. Take a screenshot of that and post it back here.
if you start the executable from a command window or from visual studio poroject (shift f5) you might get detail info in the output window.
if not, you could download depends.exe (dependency walker) to find the missing dll. for example from http://www.dependencywalker.com/
probably simpler is to reinstall all MS Office programs and MS Office redistributables.
Sara
if not, you could download depends.exe (dependency walker) to find the missing dll. for example from http://www.dependencywalker.com/
probably simpler is to reinstall all MS Office programs and MS Office redistributables.
Sara
sarabande,
That's a pretty useful app for folks who develop using more traditional products but an Access application is not an executable and so this tool would not work on it.
That's a pretty useful app for folks who develop using more traditional products but an Access application is not an executable and so this tool would not work on it.
ASKER
Hi - Just a couple of things
1) I'm not asking to have the code I attached corrected - for the reason given below (and previously stated in my original question)
2) I can't see why you need to see the References library but I will include it just in case (see attached file).
As I stated earlier - the application is working fine on 9 - 10 other PCs (so the code is not the problem) and I checked the References in the frontend Access 2010 application that I COPIED onto the PC that is throwing the missing DLL error.
What I'm seeking is some way to either step through the execution of the application to see if I can isolate the name of the missing DLL - eg Event Viewer or using some other method that someone else knows of.
PS: I tried using Event Viewer by stepping through the execution of the code but I couldn't see any reference to a missing DLL. Maybe I wasn't looking in the right place.
Reference-Library.png
1) I'm not asking to have the code I attached corrected - for the reason given below (and previously stated in my original question)
2) I can't see why you need to see the References library but I will include it just in case (see attached file).
As I stated earlier - the application is working fine on 9 - 10 other PCs (so the code is not the problem) and I checked the References in the frontend Access 2010 application that I COPIED onto the PC that is throwing the missing DLL error.
What I'm seeking is some way to either step through the execution of the application to see if I can isolate the name of the missing DLL - eg Event Viewer or using some other method that someone else knows of.
PS: I tried using Event Viewer by stepping through the execution of the code but I couldn't see any reference to a missing DLL. Maybe I wasn't looking in the right place.
Reference-Library.png
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Did you look at the references on the computer where the app fails? Open any code module, go to Tools/References. Look for "MISSING". When you have a missing reference, the actual instruction that fails usually has nothing to do with the missing reference, Access simply fails on the first instruction executed that requires ANY reference library.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Hi All ant et al
My apologies for being so slack in getting back to you all but unfortunately more urgent matters raised their ugly heads.
Following up Scott McDaniel comments I revisited the Reference Library issue.
I currently have Access 2010 and Access 2016 installed on my computer. I need Access 2010 as this version of Access supports .adp applications where as Access 2013 / Access 2016 don't., consequently, I need both Access 2010 and Access 2016 given I have different users - some requiring access to SQL backend databases while others just require Access databases
It appears that by installing Access 2016 it has updated the version 14 Reference Library with an Access 2016 DLL - specifically
Microsoft Office 14.0 Access Database engine Object Library with Microsoft Office 16.0 Access Database engine Object Library.
I will now have to find a way to update the version 14 registry with the original Microsoft Office 14.0 Access Database engine Object Library Dll while maintaining the 16 registry in its current state.
One would have thought Microsoft should have created separate registries for each version of Access rather than relying on a single registry.
Anyway many thanks for all your suggestions
My apologies for being so slack in getting back to you all but unfortunately more urgent matters raised their ugly heads.
Following up Scott McDaniel comments I revisited the Reference Library issue.
I currently have Access 2010 and Access 2016 installed on my computer. I need Access 2010 as this version of Access supports .adp applications where as Access 2013 / Access 2016 don't., consequently, I need both Access 2010 and Access 2016 given I have different users - some requiring access to SQL backend databases while others just require Access databases
It appears that by installing Access 2016 it has updated the version 14 Reference Library with an Access 2016 DLL - specifically
Microsoft Office 14.0 Access Database engine Object Library with Microsoft Office 16.0 Access Database engine Object Library.
I will now have to find a way to update the version 14 registry with the original Microsoft Office 14.0 Access Database engine Object Library Dll while maintaining the 16 registry in its current state.
One would have thought Microsoft should have created separate registries for each version of Access rather than relying on a single registry.
Anyway many thanks for all your suggestions
Unless you are using some A2016 specific feature, you are better off sticking with the A2010 and uninstalling O2916. If you want to keep both versions installed, the best method is to use a VM. Keep the version you want to work with as your default version of Offfice and use the other version only inside the VM. If you don't do that, you'll be fighting this problem ever time you distribute a new version.
Remember to match the Access versions....maybe this PC has a different patch level..