locked
connectin to access db RRS feed

  • Question

  • User-1680333004 posted

    i face a bif problem

    how to connect to access db in asp.net

    the DB is on another pc

    the path is

    \\emp-pc\c$\user.mdb

    the user on pc is

    administrator

    and pw is 1234

    what the best connection string

    Sunday, November 16, 2008 8:28 AM

Answers

  • User-1509636757 posted

    probably this tutorial will help you: Connecting to a Microsoft Access database with ASP.NET

    the DB is on another pc
     

    you can Impersonate the application.

    you need to change your “web.config” file by providing the necessary “impersonation” configuration.  Open the “web.config” file of your web application and insert the following line just below the  “<system.web>” tag:

    <identity impersonate="true"
     userName="computername\administrator" password="password" />

    Replace the “computername” with your system name and “password” with the password of the “administrator” account.  You can also replace “administrator” with any other customized user account with respective privileges.

     

    hope it helps./.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Sunday, November 16, 2008 9:03 AM

All replies

  • User-1509636757 posted

    probably this tutorial will help you: Connecting to a Microsoft Access database with ASP.NET

    the DB is on another pc
     

    you can Impersonate the application.

    you need to change your “web.config” file by providing the necessary “impersonation” configuration.  Open the “web.config” file of your web application and insert the following line just below the  “<system.web>” tag:

    <identity impersonate="true"
     userName="computername\administrator" password="password" />

    Replace the “computername” with your system name and “password” with the password of the “administrator” account.  You can also replace “administrator” with any other customized user account with respective privileges.

     

    hope it helps./.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Sunday, November 16, 2008 9:03 AM
  • User-1680333004 posted

    its  not work i have this error

     

     

    Configuration Error

    Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

    Parser Error Message: Could not create Windows user token from the credentials specified in the config file. Error from the operating system 'Logon failure: unknown user name or bad password.
    '

    Source Error:

    Line 12: 	<connectionStrings/>
    Line 13: 	<system.web>
    Line 14: 		<identity impersonate="true" userName="id-server\administrator" password="123"/>
    Line 15: 		<!-- 
    Line 16:             Set compilation debug="true" to insert debugging 

    Monday, November 17, 2008 1:39 AM