Triggering Client side script in the event of Data

Results 1 to 3 of 3

Thread: Triggering Client side script in the event of Data

  1. #1
    Laksh Nukala Guest

    Default Triggering Client side script in the event of Data

    I am storing data entered by the user in hidden form variables which would be used to update the database. In the event of an error, I am currently rolling back the transaction and showing the user an error message. When the user hits the "back" button all the work is lost which the user has to key in again. The solutions that I thought of were trying to preserve the values in a cookie, but the size of the data far exceeded the limits set by the browser. The seconfd thought that came to my mind was to try and save the values to an Excel spreadsheet by reading off the values in the form (hidden variables). The problem that I am facing with this approach is this: How to trigger the movement of data to Excel based on the error code? Is there anyone out there who could show a way of achieving this?<BR><BR>Thanks in advance!

  2. #2
    Heaven's Martini Guest

    Default umm

    Well,<BR><BR>I have no idea what you are asking,<BR>but in your case, what i do is this.<BR><BR>on error, <BR>response.write "There was problem <BR>"<BR>response.write "Chances are you proved how stupid you are when you screwed up the data<BR>"<BR>response.write "Press &#060;a href=""javascript:history.go(-1);""&#062;Here&#060;/a&#062; to go back and fix whatever it is you broke.<BR>"<BR>response.end<BR><BR>its not suave&#039; but, hey its simple, straightforward and works.

  3. #3
    Join Date
    Dec 1969

    Default why not do this...

    You post your form... Then if they goofed on the page... Re-Direct them to the page where they enter the information and pass the querystring back to that page.<BR><BR>In your editing page, set it so it automatically sets the values of your fields to the values passed to the page, so they don&#039;t have to fill them out again..<BR><BR>eg:<BR>&#060;a href="editpage.asp?&#060;%=request.servervariables ("query_string")%&#062;"&#062;Click here&#060;/a&#062;<BR><BR>or do a response.redirect to that URL...<BR><BR>-- Wholsea

Posting Permissions

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