Results 1 to 7 of 7
  1. #1
    Join Date
    Feb 2004
    Posts
    9

    Unanswered: INSERT records into MsAcess using vbscript

    I have tried a few different things to get my website to insert a simple record into my database using the following code:
    % @LANGUAGE ="VBSCRIPT" %>
    <%
    Set Conn = server.CreateObject("ADODB.connection")
    conn.open "userdata"

    sql = "insert into users(User_Name,Passwrd) values('Jenkat', '123456')"
    set rs = Conn.execute(sql)
    conn.close

    %>
    <html>
    <body>



    </body>
    </html>
    I have also changed the security settings for the database in IIS, so i was wondering what i was doing wrong because the following error is displayed:
    Error Type:
    Microsoft OLE DB Provider for ODBC Drivers (0x80004005)
    [Microsoft][ODBC Microsoft Access Driver] Operation must use an updateable query.
    /fffan/create.asp, line 7

  2. #2
    Join Date
    Feb 2004
    Posts
    5
    i cannot full asure,but these type of problem occur when database properties is checked with only read-only option, just unchecked the read-only option

  3. #3
    Join Date
    Feb 2004
    Posts
    9
    sorry to appear thick, but where exactly is this read-only option, is it under IIS?
    Thanks for your help anyways!

  4. #4
    Join Date
    Feb 2004
    Posts
    5
    Based on controlpanel you used there will be a database properties
    in IIS it will be easily found

  5. #5
    Join Date
    Feb 2004
    Posts
    9
    Thanks i'll try that one out!

  6. #6
    Join Date
    Feb 2004
    Posts
    9
    Thanks I found it, but I'm still getting the error.
    I've tried everything I can think of now.
    Do you actually have to change the database properties in Acess by any chance?

  7. #7
    Join Date
    Feb 2004
    Posts
    9
    I've sorted it out now.. Few things were looking worried. For all you viewers, I'm now off to post the solution, so hopefully, no-one else spends so much time trying to get this to work!

Posting Permissions

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