Guestbook with ASP and Access

Results 1 to 2 of 2

Thread: Guestbook with ASP and Access

  1. #1
    Join Date
    Dec 1969
    Posts
    1

    Default Guestbook with ASP and Access

    I&#039;ve been working on a guestbook but i&#039;m a little stuck. Actually, I know the code is good because it works on my Personal Web Server. However when I post it to my web-site I get an HTTP 500 error. Here&#039;s the code i&#039;m using:<BR><BR>&#060;%<BR>LastName = Request.Form("Last")<BR>FirstName = Request.Form("First")<BR>Address = Request.Form("Address")<BR>City = Request.Form("City")<BR>State= Request.Form("State")<BR>ZipCode = Request.Form("Zip")<BR>Phone = Request.Form("Phone")<BR>Fax = Request.Form("Fax")<BR>Email = Request.Form("Email")<BR>Comments = Request.Form("Comments")<BR><BR>Set Conn = Server.CreateObject("ADODB.Connection") <BR><BR>Conn.Provider = "Microsoft.Jet.OLEDB.4.0" <BR>Conn.ConnectionString = "Data Source=" & Server.MapPath ("fpdbgtbay.mdb") <BR>Conn.Open <BR><BR>Set AddRS = Server.CreateObject("ADODB.Recordset")<BR>AddRS.Op en "Select * from guestbook", Conn, 1,3<BR><BR>AddRS.addNew<BR>AddRS("LastName") = LastName<BR>AddRS("FirstName") = FirstName<BR>AddRS("Address") = Address<BR>AddRS("City") = City<BR>AddRS("State") = State<BR>AddRS("Zip") = ZipCode<BR>AddRS("Phone") = Phone<BR>AddRS("Email") = Email<BR>AddRS("Date") = Date<BR>AddRS.UPDATE<BR>Set AddRS = Nothing<BR>Set Conn = Nothing<BR>Session.Abandon<BR>%&#062;<BR>Like I said, it works well on Microsoft Personal Web server but not on my providers server. Think it&#039;s a permissions issue? Thanks for the help!

  2. #2
    Join Date
    Dec 1969
    Posts
    1

    Default RE: Guestbook with ASP and Access

    Change your code to this and try it<BR><BR> AddRS.CursorLocation = 3<BR> AddRS.CursorType = 3<BR> AddRS.LockType = 4<BR> AddRS.Open "Select * from guestbook", Conn<BR> .<BR> .<BR> .<BR> AddRS.UpdateBatch &#039;use this instead of AddRS.Update

Posting Permissions

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