Results 1 to 3 of 3

Thread: Runtime error 3061 - HELP!!

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    May 1999
    Location
    Littlehampton, W Sussex GB
    Posts
    203

    Post

    Using the following code:
    Set db = DBEngine.Workspaces(0).OpenDatabase("C:\access files\S and B.mdb")
    List1.Clear

    Select Case Index

    Case 0:
    sSQL = "Select * from [Customers Query Name] where [Company Name] Like '" & Text1.Text & "*'"
    Set rs = db.OpenRecordset(sSQL, dbOpenDynaset)
    List1.Enabled = False

    I get an error on my set rs line but when I look at a different database with fewer tables in, its fine any ideas??

  2. #2
    Hyperactive Member
    Join Date
    Feb 2000
    Posts
    284

    Post

    Maybe you could use an error handler and message box
    on error goto Handler
    .
    .
    .
    Handler :
    msgbox err.description

    to get better details of the problem

  3. #3
    Guru Clunietp's Avatar
    Join Date
    Oct 1999
    Location
    USA
    Posts
    1,844

    Post

    get rid of dbOpenDynaset and try it again, sometimes those parameters cause errors in certain situations....

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width