Results 1 to 6 of 6

Thread: Ado connection on passworded Access DB

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Nov 2000
    Posts
    25

    Unhappy

    Hi

    I'm trying to open the following ADO Connection


    Dim conn as adodb.connection

    Conn.Open "Provider=Microsoft.Jet.OleDb.3.51;Datasource=C:\program files\sm2000\databases\maindb.mdb", "", "anchor"

    where anchor is the password, I've tried putting Admin in for user or leaving that part blank as above

    Either way I get the error

    "Can't start your application. The workgroup information file is missing or opened exclusively by another user"

    This is a stand alone computer so noone else is accessing the db

    I have no problem opening non password protected databases and the database in question opens fine in DAO

    any ideas would be appreciated

    Mark

  2. #2
    New Member
    Join Date
    Nov 2000
    Posts
    10
    Classic common problem: you have to assign the password to the OLEDB:Database Password of the Jet Engine.

    Here is what your code should look like:

    Conn.Open "Provider=Microsoft.Jet.OleDb.3.51;Datasource=C:\program files\sm2000\databases\maindb.mdb;" _

    & "Jet OLEDB:Database Password=anchor"

    That should make it work.

    Here is the "authority" for the answer:


    http://www.vb2themax.com/Item.asp?Pa...at=1100&ID=324
    TTFN,

    Smashing Piggy

    "Beware of Big Bad Wolf dressed in Tigger clothes"

  3. #3

    Thread Starter
    Junior Member
    Join Date
    Nov 2000
    Posts
    25

    Unhappy Now I can't find installable ISAM

    Hi

    Thanks for reply - I tried the above solution but now I get a message - can't find installable ISAM ??

  4. #4
    New Member
    Join Date
    Nov 2000
    Posts
    10
    <i>get a message - can't find installable ISAM ??</i>

    That tends to indicate that MDAC or the Jet Engine is not installed properly. There is either a file missing or a file that is not registered.

    There is a know bug as well:

    http://support.microsoft.com/support...-US&SD=gn&FR=0


    Hope that helps.

    TTFN,

    Smashing Piggy

    "Beware of Big Bad Wolf dressed in Tigger clothes"

  5. #5
    Addicted Member
    Join Date
    Oct 2000
    Location
    Orlando, FL
    Posts
    253
    Hey, there is nothing wrong with the installation. This is
    the code I use to access our database at work here:
    Code:
    Dim dbsData As New ADODB.Connection
    
    With dbsData
        .ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;" & _
              "Data Source=\\192.168.0.1\Database\Data.mdb;" & _
              "Jet OLEDB:Database Password=My Password"
        .Open
    End With
    Just put in your password and you should be set...let me know.
    Always looking for a better and faster way!

  6. #6
    Addicted Member
    Join Date
    Oct 2000
    Location
    Orlando, FL
    Posts
    253
    You can also open a connection like this:
    Code:
    Dim dbsData As New ADODB.Connection
    
    With dbsData
        .Provider = "Microsoft.Jet.OLEDB.4.0"
        .Properties("Data Source") = "\\192.168.0.1\Database\Data.mdb"
        .Properties("Jet OLEDB:Database Password") = Password
        .Open
    End With
    There are a bunch of ways to write the code. I hope this helps.
    Always looking for a better and faster way!

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