Print Page | Close Window

Forcing User to Fill Out Second Form

Printed From: Web Wiz Forums
Category: General Discussion
Forum Name: Classic ASP Discussion
Forum Description: Discussion on Active Server Pages (Classic ASP).
URL: https://forums.webwiz.net/forum_posts.asp?TID=12436
Printed Date: 30 March 2026 at 9:50pm
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: Forcing User to Fill Out Second Form
Posted By: Misty
Subject: Forcing User to Fill Out Second Form
Date Posted: 04 November 2004 at 1:25am
I have two different forms that are on ASP pages that users must fill out. Is there a way for me to force the user to fill out the second form on the next ASP Page if he/she has filled out the first form? If the user starts to leave the page, I would like for a message box to show up saying, "You must fill out this form". I think that there may be a Javascript code for this somewhere.



Replies:
Posted By: dpyers
Date Posted: 04 November 2004 at 11:31am

google for "document.body.onunload". Should be lots of javascripts that will do what you want depending on the destination.

Most pop-up blockers will defeat this though. A better solution would be to convert the asp to asp.net and use the page unload event.



-------------

Lead me not into temptation... I know the short cut, follow me.



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net