Asp first page load (validation) help!!!!

Discussion in 'ASP General' started by x, Nov 3, 2003.

  1. x

    x Guest

    Im working with an ASP page, with vbscript.

    I am doing a bit of data validation on the following page and sending
    the users back to the previous page if the required fields are not
    filled in. This works great, only the warning that the required
    fields were not filled in is now showing up on the first page when you
    first enter the site.

    how can I stop this from occurring?

    thanks
    x, Nov 3, 2003
    #1
    1. Advertising

  2. x

    Dan Brussee Guest

    Create and look for a form element that should NOT be there when
    loading the page first time.

    <%
    if request.form("ACT") = "SAVE" then
    ' Validate
    end if
    %>
    <FORM ... >
    <INPUT TYPE=HIDDEN NAME="ACT" VALUE="SAVE">
    ....
    </FORM>

    When first loading the page, the value for request.form("ACT") will be
    blank. However, after submitting back to itself, it will be "SAVE".


    On 3 Nov 2003 04:52:32 -0800, (x) wrote:

    >Im working with an ASP page, with vbscript.
    >
    >I am doing a bit of data validation on the following page and sending
    >the users back to the previous page if the required fields are not
    >filled in. This works great, only the warning that the required
    >fields were not filled in is now showing up on the first page when you
    >first enter the site.
    >
    >how can I stop this from occurring?
    >
    >thanks
    Dan Brussee, Nov 3, 2003
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Chris
    Replies:
    0
    Views:
    549
    Chris
    Jul 15, 2003
  2. venky

    Page Load and webcontrol page load

    venky, Jul 6, 2005, in forum: ASP .Net
    Replies:
    5
    Views:
    3,078
    venky
    Jul 11, 2005
  3. Matcon
    Replies:
    3
    Views:
    21,528
    Matcon
    May 28, 2008
  4. Mike Dee
    Replies:
    3
    Views:
    307
    Mamidipalli
    Mar 1, 2006
  5. sherifffruitfly
    Replies:
    0
    Views:
    109
    sherifffruitfly
    Apr 25, 2007
Loading...

Share This Page