Results 1 to 5 of 5
  1. #1
    Bo Hansson is offline Novice
    Windows 10 Access 2016
    Join Date
    Oct 2017
    Posts
    3

    Command OpenRecordset leads to Error 48

    I´m controlling an MS Access Database 2016 from a VB application developed under MS Word. It have worked for years, through different Word and Access versions, but suddenly (over night) I get Error 48 (Cannot load DLL file) when executing an OpenRecordset command. What has happened, and how to mend it?

  2. #2
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,524
    what DLL?
    are you opening a form with data?
    are you using code to do something to a recordset? can you show us the error point?

    are there any missing DLL in VBE, tools, references?

  3. #3
    Bo Hansson is offline Novice
    Windows 10 Access 2016
    Join Date
    Oct 2017
    Posts
    3
    I dont know what DLL. Here is the code (execution stops on second line):

    Set dbsData = OpenDatabase(strSökväg & "Databas\Lotta 2000.mdb")
    Set rstData = dbsData.OpenRecordset("Data")

    But, again - it has worked for years Now, suddenly this problem!

  4. #4
    John_G is offline VIP
    Windows 7 32bit Access 2010 32bit
    Join Date
    Oct 2011
    Location
    Ottawa, ON (area)
    Posts
    2,615
    "Overnight" - Might MS have automatically applied some sort of update (they like to do that) that you didn't notice? If so it could be that the update failed to complete properly, resulting in a missing DLL. As Ranman suggessted, check your references settings (while in any VBA module, select Tools - References) to see if any are missing. Also try recompiling your code to see if you get any weird errors, which can also indicate a references problem.

  5. #5
    Bo Hansson is offline Novice
    Windows 10 Access 2016
    Join Date
    Oct 2017
    Posts
    3
    Looking at the references there are eight marked as available, none as missing. I´ve also uninstalled the latest Office 2016 update, but with no effect.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 3
    Last Post: 02-26-2016, 12:34 PM
  2. Replies: 2
    Last Post: 10-09-2014, 10:53 AM
  3. dbSeeChanges does not fix openrecordset error
    By lringstad in forum Access
    Replies: 1
    Last Post: 12-03-2013, 03:33 PM
  4. Replies: 7
    Last Post: 07-24-2013, 02:01 PM
  5. db.OpenRecordset error
    By jscriptor09 in forum Programming
    Replies: 4
    Last Post: 01-27-2012, 12:17 AM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums