|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
database access
I am new to ASP and have been having lots of fun/sucsess learning it however i have hit a wall.
What i need to do is get some info from an Access database that i have, and display it (no problems here). Then i need the user to be able to edit the info and save thier changes back to the database. I have set things up so that the user sees some html forms that show them options for changeing the filed in the database. These options are generated dynamically from a different table in the same database. I can do all of this just fine but what i can't do is save the info back to the database i get this following error: Error Type: Microsoft OLE DB Provider for ODBC Drivers (0x80004005) [Microsoft][ODBC Microsoft Access Driver] Cannot update. Database or object is read-only. So here is the code where i open my database connection: <% Dim objConn, Record Set objConn = Server.CreateObject("ADODB.Connection") objConn.Open "DRIVER={Microsoft Access Driver (*.mdb)};_ DBQ=" & Server.MapPath("LAPD.mdb") Set Record = Server.CreateObject("ADODB.Recordset") Record.Open "SELECT * FROM Projects WHERE City= '" & City & _"' ORDER BY City ", objConn, adOpenDynamic, adLockOptimistic Can anyone see why i can't edit the database? I think i aopendit dynamically and with an optimistic lock. Thanks |
|
#2
|
|||
|
|||
|
Check the windows file permissions and make sure the .mdb file isn't marked as "read-only"
|
|
#3
|
|||
|
|||
|
check the NTFS file permissions...
if u are using:
1)win2k... check that 2 users: "IUSR_[pc name] and IWAM_[pc name]" are inside and are given *FULL* permissions... 2)winxp pro check that "use simple file sharing" is *DISABLED* under edit--> folder options.. then follow the instructions for win2k.. these are the 2 "users" that actually access the files in ur http server. |
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > ASP Programming > database access |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|