please help

Discussion in 'Databases' started by anhinternat, Dec 18, 2003.

Thread Status:
Threads that have been inactive for 5 years or longer are closed to further replies. Please start a new thread.
  1. I am using an asp page to display data from Access database.But i have not being able to connect to my Access Database. I need the proper connection string. i used:

    MyConn.Open "Provider=Microsoft.Jet.Oledb.4.0;data source=www.anhinternationaltransfers.com\anhinternat\_database\Ahn.mdb"
    where:
    www.anhinternationaltransfers.com is the name of my site.
    anhinternat is the name of my directory.
    _database is where my data base file is.
    Ahn.mdb is the name of the database.

    But i can't still connect to my database as am having errors. Pls i need someone's urgent attension. I need to get this job done b4 d weekend. cheers
     
  2. Takeshi Eto

    Takeshi Eto DiscountASP.NET Staff

    Look in your Control Panel Account Information section for your full path. Alternatively you can also use Server.MapPath.
     
  3. quote:Originally posted by dasp

    Look in your Control Panel Account Information section for your full path. Alternatively you can also use Server.MapPath.


    </blockquote id="quote"></font id="quote">

    i have done somthing like this:
    MdbFilePath = Server.MapPath("Anh.mdb")
    MyConn.Open "FILEDSN=anhinternat_franky.dsn"

    but i still did not get the really result.

    i created a dsn called frank.dsn but i still didn't get a result. pls i need a straight answer as i have looked through the contol panel and i don't have a result yet.
    cheers
     
  4. quote:Originally posted by dasp

    Look in your Control Panel Account Information section for your full path. Alternatively you can also use Server.MapPath.


    </blockquote id="quote"></font id="quote">

    i have done somthing like this:
    MdbFilePath = Server.MapPath("Anh.mdb")
    MyConn.Open "FILEDSN=anhinternat_franky.dsn"

    but i still did not get the really result.

    i created a dsn called frank.dsn but i still didn't get a result. pls i need a straight answer as i have looked through the contol panel and i don't have a result yet.
    cheers
     
  5. quote:Originally posted by anhinternat

    MyConn.Open "Provider=Microsoft.Jet.Oledb.4.0;data source=www.anhinternationaltransfers.com\anhinternat\_database\Ahn.mdb"
    where:
    www.anhinternationaltransfers.com is the name of my site.
    anhinternat is the name of my directory.
    _database is where my data base file is.
    Ahn.mdb is the name of the database.

    But i can't still connect to my database as am having errors. Pls i need someone's urgent attension. I need to get this job done b4 d weekend. cheers
    </blockquote id="quote"></font id="quote">
    you need the fysical file location of your database. In the control panel, under Account Management > Account information, you find the path to your webapplication-root (Server path), i.e. something like e:\web\anhinternat\htdocs\.

    You should be able to open your connection as follows:
     
  6. hey,
    i got it at last. Thanks Steurm and the other guy for your contributions.
    cheers
    julia
     
Thread Status:
Threads that have been inactive for 5 years or longer are closed to further replies. Please start a new thread.

Share This Page