Problems w/ Access

Results 1 to 4 of 4

Thread: Problems w/ Access

  1. #1
    Jenny Guest

    Default Problems w/ Access

    I am trying to connect to an Access database with the following code:<BR>dim strConnect, objRS, varUserInput, strSQL<BR>set strConnect = Server.CreateObject ("ADODB.Connection")<BR>with strConnect<BR> .Provider = "Microsoft.Jet.OLEDB.4.0"<BR> .Properties ("Jet OLEDB:System Database") = "path to .mdw file"<BR> .Open "path to database", "uid", "password"<BR> end with<BR>varUserInput = Request.Form ("MyJobNumber")<BR> <BR>set objRS = Server.CreateObject ("ADODB.Recordset")<BR>objRS.Open "tblInvoice", strConnect,1,3<BR><BR>strSQL = "Select Invoice, Jobnumber, Jobname, Shipdate, Brncost, Desc1 from tblInvoice where Jobnumber = " & varUserInput & ";"<BR><BR>set objRS = strConnect.Execute (strSQL)<BR><BR>I am getting an error:<BR>The Microsoft Jet database engine cannot open the file &#039&#039. It is already opened exclusively by another user, or you need permission to view its data.<BR>and it points to the line:<BR>.Properties ("Jet OLEDB:System Database") = "path to .mdw file"<BR><BR>I have also tried it with a DSN, and I get the same error but it points to the line:<BR>objRS.Open "tblInvoice", strConnect,1,3<BR><BR>

  2. #2
    iyyappan n iyer Guest

    Default i think

    u need to open the mdbb file and set it to open in shared mode.<BR>tools-&#062;options-&#062;advanced-&#062;open mode (is , i think, the menu path)

  3. #3
    Jenny Guest

    Default RE: i think

    Sorry- it already was in shared mode. Any other ideas?

  4. #4
    Join Date
    Dec 1969

    Default Anyone?...Bueller?

    Same problem here. Anyone got any ideas?

Posting Permissions

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