dynamic text box and post backs - HELP!!

Discussion in 'ASP .Net' started by Rosanne, Jun 17, 2005.

  1. Rosanne

    Rosanne Guest

    I have an aspx page that contains a custom built component. Thi
    component contains a panel. At runtime text boxes are built and adde
    to the controls collection of the panel on an as needed basis. Thes
    text boxes are built as server-side controls with the AutoPostBac
    property turned on. A TextChanged event handler is also built int
    each text box. So, when a value is entered into the text box and th
    user tabs off of the field, it causes a post back and the TextChange
    even to fire. The problem comes in when the user enters a value int
    the text box, but does NOT tab off of the field. Instead they clic
    the save button on the main page. This save button click causes a pos
    back. What happens is 2 post backs are occurring - I guess one for th
    button click and one for the text box. The TextChanges event on th
    text box fires twice causing the value entered to be doubled. I can'
    turn AutoPostBack on the text box off because that creates another se
    of problems for the web page. I've tried everything I can think of t
    "blank" out the value of the text box between the 2 posts, but canno
    find a way to do it. Any ideas? Does this even make sense? Thanks i
    advance for any ideas or suggestions!!! Oh, this is all developed i
    vb.net..

    --
    Rosann
    -----------------------------------------------------------------------
    Rosanne's Profile: http://www.highdots.com/forums/member.php?userid=28
    View this thread: http://www.highdots.com/forums/showthread.php?t=151946
    Rosanne, Jun 17, 2005
    #1
    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. Mark S.

    Post Backs

    Mark S., Aug 13, 2003, in forum: ASP .Net
    Replies:
    4
    Views:
    774
    George Ter-Saakov
    Aug 13, 2003
  2. ALPO

    Stopping post backs possible??

    ALPO, Nov 21, 2003, in forum: ASP .Net
    Replies:
    2
    Views:
    316
    Joao S Cardoso [MVP]
    Nov 21, 2003
  3. Jason
    Replies:
    5
    Views:
    366
    darrel
    Dec 10, 2004
  4. Dirc Khan-Evans
    Replies:
    6
    Views:
    584
    Rosanne
    Oct 20, 2005
  5. ~john
    Replies:
    5
    Views:
    340
    Mark Rae
    Dec 19, 2006
Loading...

Share This Page