Felix18807
Programmer
Hi All,
I hope this post is okay I apologise if I've made any faux pas.
Basically I've made a small Access tool that adds some data to a spreadsheet after comparing it to an master table. It works fine on my machine (2010) but throws error messages relating to library references when I try to get it working on other peoples machines.
I have tried coding in library reference links into the form on load event but due to my lack of experience this did not seem to work.
I also tried packaging the tool with the Access 2010 runtime but this also failed.
The references used are -
Microsoft Office 14.0 Access database engine object library
MIcrosoft ActiveX Data Object 6.0 Library
Microsoft Office 14.0 Object library
Microsoft Visual Basic for Applications Extensibility 5.3
Microsoft Excel 14.0 Object library
Microsoft Word 14.0 Object library
Microsoft Internet controls
I have tried this -
On Error Resume Next
Dim i As Long
Dim theRef As Variant
For i = References.Count To 1 Step -1
Set theRef = References.Item(i)
If theRef.IsBroken = True Then
References.Remove theRef
End If
Next i
References.AddFromFile ("C:\PROGRA~1\COMMON~1\MICROS~1\VBA\VBA7\VBE7.DLL")
References.AddFromFile ("C:\program files\common files\microsoft shared\dao\dao360.dll")
References.AddFromFile ("C:\Program Files\Common Files\Microsoft Shared\OFFICE14\ACEDAO.DLL")
References.AddFromFile ("C:\Program Files\Common Files\Microsoft Shared\OFFICE14\MSO.DLL")
References.AddFromFile ("C:\Program Files\Common Files\Microsoft Shared\vba\vba6\vbe6.dll")
References.AddFromFile ("C:\Program Files\Common Files\Microsoft Shared\VBA\VBA6\VBE6EXT.OLB")
References.AddFromFile ("C:\Program Files\Common Files\Microsoft Shared\vba\vba7\vbe7.dll")
References.AddFromFile ("C:\Program Files\Common Files\System\ado\msado15.dll")
References.AddFromFile ("C:\Program Files\Microsoft Office\Office12\acedao.dll")
References.AddFromFile ("C:\Program Files\Microsoft Office\Office14\EXCEL.EXE")
References.AddFromFile ("C:\Program Files\Microsoft Office\Office14\MSACC.OLB")
References.AddFromFile ("C:\Program Files\Microsoft Office\Office14\MSWORD.OLB")
References.AddFromFile ("C:\Program Files\Microsoft Office\Office12\EXCEL.EXE")
References.AddFromFile ("C:\Program Files\Microsoft Office\Office12\MSACC.OLB")
References.AddFromFile ("C:\Program Files\Microsoft Office\Office12\MSWORD.OLB")
References.AddFromFile ("C:\Windows\system32\stdole2.tlb")
References.AddFromFile ("c:\windows\system32\ieframe.dll")
but this failed to stop the error.
Unfortunately I dont have access to a PC with an older version of access to fix the issue and I don't want to keep sending unworkable tools to my client.
Can anyone offer any help on this? (you'll have to be explicit I'm not to bright)
If necessary I will upload the tool.
Thanks in advance
I hope this post is okay I apologise if I've made any faux pas.
Basically I've made a small Access tool that adds some data to a spreadsheet after comparing it to an master table. It works fine on my machine (2010) but throws error messages relating to library references when I try to get it working on other peoples machines.
I have tried coding in library reference links into the form on load event but due to my lack of experience this did not seem to work.
I also tried packaging the tool with the Access 2010 runtime but this also failed.
The references used are -
Microsoft Office 14.0 Access database engine object library
MIcrosoft ActiveX Data Object 6.0 Library
Microsoft Office 14.0 Object library
Microsoft Visual Basic for Applications Extensibility 5.3
Microsoft Excel 14.0 Object library
Microsoft Word 14.0 Object library
Microsoft Internet controls
I have tried this -
On Error Resume Next
Dim i As Long
Dim theRef As Variant
For i = References.Count To 1 Step -1
Set theRef = References.Item(i)
If theRef.IsBroken = True Then
References.Remove theRef
End If
Next i
References.AddFromFile ("C:\PROGRA~1\COMMON~1\MICROS~1\VBA\VBA7\VBE7.DLL")
References.AddFromFile ("C:\program files\common files\microsoft shared\dao\dao360.dll")
References.AddFromFile ("C:\Program Files\Common Files\Microsoft Shared\OFFICE14\ACEDAO.DLL")
References.AddFromFile ("C:\Program Files\Common Files\Microsoft Shared\OFFICE14\MSO.DLL")
References.AddFromFile ("C:\Program Files\Common Files\Microsoft Shared\vba\vba6\vbe6.dll")
References.AddFromFile ("C:\Program Files\Common Files\Microsoft Shared\VBA\VBA6\VBE6EXT.OLB")
References.AddFromFile ("C:\Program Files\Common Files\Microsoft Shared\vba\vba7\vbe7.dll")
References.AddFromFile ("C:\Program Files\Common Files\System\ado\msado15.dll")
References.AddFromFile ("C:\Program Files\Microsoft Office\Office12\acedao.dll")
References.AddFromFile ("C:\Program Files\Microsoft Office\Office14\EXCEL.EXE")
References.AddFromFile ("C:\Program Files\Microsoft Office\Office14\MSACC.OLB")
References.AddFromFile ("C:\Program Files\Microsoft Office\Office14\MSWORD.OLB")
References.AddFromFile ("C:\Program Files\Microsoft Office\Office12\EXCEL.EXE")
References.AddFromFile ("C:\Program Files\Microsoft Office\Office12\MSACC.OLB")
References.AddFromFile ("C:\Program Files\Microsoft Office\Office12\MSWORD.OLB")
References.AddFromFile ("C:\Windows\system32\stdole2.tlb")
References.AddFromFile ("c:\windows\system32\ieframe.dll")
but this failed to stop the error.
Unfortunately I dont have access to a PC with an older version of access to fix the issue and I don't want to keep sending unworkable tools to my client.
Can anyone offer any help on this? (you'll have to be explicit I'm not to bright)
If necessary I will upload the tool.
Thanks in advance