Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

run time error 3125 - the database engine can't find 'worksheet'

Status
Not open for further replies.

seosamh

Programmer
Aug 2, 2000
29
IE
I am trying to run an application where I import data from an excel spreadsheet. While this works fine in the uncompiled version, when I make an exe I am given the above error and told that the application can't find the worksheet. The offending excel worksheet is called 'HiddenResults', and the code is given as follows:

If MsgBox(sMsg, vbYesNo, "Import Results") = vbYes Then
sSheetName = App.Path & "\" & sFile
Set dbExcelSheet = OpenDatabase(sSheetName, False, True, "Excel 8.0;")
Set rstHiddenSheet = dbExcelSheet.OpenRecordset("HiddenResults$")
Else
Exit Sub
End If


Any help will be much appreciated.

Seosamh
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top