Results 1 to 3 of 3
  1. #1
    4 Star Lounger
    Join Date
    Feb 2001
    Location
    Gillingham, Kent, England
    Posts
    511
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Long shot references probs. (VB6)

    Im not very familiar with the use of references within VB. I have used some functions which require references but not many.

    I have a program created by a previous developer. Currently Microsoft ActiveX Data Objects 2.0 Library is selected. For installing the program Install shield is being used. MDAC 2.1 has a much better installation using install shield, so I thought it would be a simple case of changing the reference to 2.1 (thinking backward compatibility would be okay).... it appears I was wrong. The program still requires MDAC 2.0 installed.

    Is there an obvious thing that i'm missing concerning compatibility between the 2.0 and 2.1 references or would I need to go through the program and find the code that is using the reference?
    Please note, the only reference i've ever really used is the one that enable Outlook processes to be used, I have no idea what process are available using Microsoft ActiveX Data Objects 2.0 Library or Microsoft ActiveX Data Objects 2.1 Library. Any ideas on where I can find information on what the references do would also be much appreciated.

  2. #2
    4 Star Lounger
    Join Date
    Feb 2001
    Location
    Gillingham, Kent, England
    Posts
    511
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Long shot references probs. (VB6)

    MORE INFO:

    I've narrowed down where the error occurs. This is the code (gsDBpath is a public variable set to the location of an access database):

    Dim RS As New ADODB.Recordset, SQL As String, strConn As String
    strConn = "Provider=Microsoft.Jet.OLEDB.3.51;Data Source=" & gsDBpath
    SQL = "SELECT UserName, Password, UserID FROM tblUsers WHERE UserName= '" & UserName & "'"
    RS.Open SQL, strConn, , , adCmdText

    The error occuring is ADO could not find the specified provider.
    Is there a method of accessing an Access 97 database using MDAC 2.1 instead of MDAC 2.0? The above code works fine with MDAC 2.0 installed even if the MDAC 2.1 reference has been ticked.

  3. #3
    4 Star Lounger
    Join Date
    Feb 2001
    Location
    Gillingham, Kent, England
    Posts
    511
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Long shot references probs. (VB6)

    A colleague managed to find the answer on the install shield knowledge base:

    Change the provider from OLEDB.3.51 to OLEDB.4.0

Posting Permissions

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