Results 1 to 4 of 4

Thread: phu

  1. #1
    phu Guest

    Default phu

    help, please.<BR>i can&#039;t add new record to my dbf file. it says files are readonly<BR>here are my codes<BR><BR> Set objConn = Server.CreateObject("ADODB.Connection")<BR> objConn.ConnectionString = "DSN=noble"<BR> objConn.Open Session("ADO_CONNECT_STRING")<BR><BR> Set objRs = Server.CreateObject("ADODB.Recordset")<BR> objRs.ActiveConnection = objConn<BR> objRs.Open "SELECT * FROM name.dbf", objConn<BR> objRs.MoveFirst<BR> Do while Not objRS.EOF<BR> objRs.MoveNext<BR> Loop<BR> objRs.AddNew<BR> objRs("name") = "ALISON"<BR><BR>

  2. #2
    error message Guest

    Default why don't you read your

    "it says files are readonly"<BR><BR>check your permissions on the folder containg your db <BR>

  3. #3
    Join Date
    Dec 1969

    Default You opened the RS read only... what do you expect???<BR><BR>objRS.Open "SELECT * FROM name.dbf", objConn<BR><BR>automatically opens the recordset readonly and with a readonly lock.<BR><BR>See the ASPFAQs (category Databases, General) to see how to do this the right way. The link to the ASPFAQs is at the top right corner of this page.<BR><BR><BR>

  4. #4
    Join Date
    Dec 1969

    Default Permissions wouldn't matter...

    ...since he opened the RS as read-only. No matter if the DB did have read/write, the RS wouldn&#039;t let him.<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