Week 3 examples don't always work. Why?

Results 1 to 3 of 3

Thread: Week 3 examples don't always work. Why?

  1. #1
    Join Date
    Dec 1969

    Default Week 3 examples don't always work. Why?

    Greets,<BR><BR>I keep getting the following errors when running the examples from week 3. ( The one&#039s where you link up to a database using the connection object. ).......<BR>----------------------------------------------------------<BR>Microsoft OLE DB Provider for ODBC Drivers error &#039 80004005&#039 <BR><BR>[Microsoft][ODBC Microsoft Access Driver] Could not use &#039(unknown)&#039 file already in use. <BR><BR>/DatabaseConnect.asp, line 5 <BR><BR>AND<BR>--------------------------------------------------------<BR>Provider error &#039 80004005&#039 <BR><BR>Unspecified error <BR><BR>/DatabaseConnect.asp, line 5 <BR>--------------------------------------------------------<BR><BR>(&#039line 5&#039 refers to - objConn.Open)<BR><BR>These errors are confusing because they don&#039t always happen. Also, the situation seems to be independent of whether Access is open with the database loaded into it. <BR><BR>The most confusing occurrence comes when after it has worked perfectly, I&#039ll hit REFRESH on the browser and get an error!<BR><BR>Basically I need to know why a connection cannot be made with a database when the code trying to do it is without errors. <BR><BR>Help would be greatly appreciated.<BR><BR>Yours, Ian.<BR><BR>

  2. #2
    Join Date
    Dec 1969

    Default RE: Week 3 examples don't always work. Why?

    I don&#039t know if this has anything to do with it, but I noticed that sometimes I had a hard time inserting info into a field in a database. When I checked the books code against book by wrox dealing specifically with asp and databases, they used objRS.Fields("fieldname")=Request.Form("fieldname" ) whereas 21 days book leaves out the .Fields portion of the objRS. Now I&#039m not saying there&#039s anything wrong with that way of doing it, but when I put in the .Fields, I haven&#039t had a problem since. Hope it helps, but if not, sorry, don&#039t know what to tell ya:)

  3. #3
    LieutenanT Guest

    Default RE: Week 3 examples don't always work. Why?

    The reason why you get errors like &#039Could not use &#039(unknown)&#039 file already in use.&#039 is that the file is in use, as the errormessage says. You&#039ve propably got Access running and have the database open in it, because then Access will open the file and will not close it until you choose to do so, so it can update the data constantly and thus stopping other programs screwing around with the data(meaning that you cannot open the file!). Blame Microcrap.<BR><BR>

Posting Permissions

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