Reset button code

Discussion in 'ASP .Net' started by John, Oct 8, 2004.

  1. John

    John Guest

    Hi

    What is the vb code that will reset a webform?

    Thanks

    Regards
    John, Oct 8, 2004
    #1
    1. Advertising

  2. John

    Lucas Tam Guest

    "John" <> wrote in news:O9PvFhMrEHA.3848
    @TK2MSFTNGP14.phx.gbl:

    > What is the vb code that will reset a webform?


    There is no code to reset a form...

    But if you want to load the form as if it were "Not Postback" you can go:
    reponse.redirect("Webpage").

    Otherwise... you can loop through the control collection like:

    For ctl as control in Page.Controls
    If GetType(ctl) is Gettype(Label) Then
    Ctyle(ctl, Label).text = ""
    End If

    Next

    --
    Lucas Tam ()
    Please delete "REMOVE" from the e-mail address when replying.
    http://members.ebay.com/aboutme/coolspot18/
    Lucas Tam, Oct 8, 2004
    #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 Lane
    Replies:
    4
    Views:
    11,219
    Chris Lane
    Nov 17, 2003
  2. angus

    a reset button

    angus, May 19, 2004, in forum: ASP .Net
    Replies:
    2
    Views:
    583
    Cliff Harris
    May 19, 2004
  3. NancyASAP
    Replies:
    2
    Views:
    15,679
    parndt
    Oct 16, 2007
  4. PC Leung
    Replies:
    1
    Views:
    443
    Murray
    Jul 9, 2004
  5. Reiner Wagner

    RESET button as an image

    Reiner Wagner, Jul 6, 2005, in forum: HTML
    Replies:
    3
    Views:
    12,992
    Vladdy
    Jul 6, 2005
Loading...

Share This Page