Results 1 to 2 of 2

Thread: Type Mismatch on OpenRecordset function

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Aug 2001
    Location
    India
    Posts
    203

    Type Mismatch on OpenRecordset function

    VB Code:
    1. Dim db As Database
    2. Dim rs As Recordset
    3. Dim ws As Workspace
    4.  
    5.     DBEngine.SystemDB = "C:\Documents and Settings\System.mdw"
    6.     Set ws = CreateWorkspace("NewWS", "user1", "", dbUseJet)
    7.     Set db = ws.OpenDatabase("C:\Documents and Settings\testimport.mdb")
    8.     Set rs = db.OpenRecordset("EquipAll")

    This returns me a Runtime error '13': Type Mismatch
    even though the return type of the OpenRecordSet function is 'Recordset' and the rs object is of type 'Recordset'

    ???

  2. #2

    Thread Starter
    Addicted Member
    Join Date
    Aug 2001
    Location
    India
    Posts
    203

    Re: Type Mismatch on OpenRecordset function

    just to tell you what Im trying to do, Im exporting excel data into Access using a macro

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