Set focus on control 2 with click event of control 1

Discussion in 'ASP .Net' started by Paul, Jul 8, 2008.

  1. Paul

    Paul Guest

    I have two dropdown boxes that post back and when a selection is made on the
    first one I want the second control to have focus on post back, using vs
    2005. I thought there was a way to set this in the properties box of control
    1 but can not remember, thanks.
     
    Paul, Jul 8, 2008
    #1
    1. Advertisements

  2. Paul

    David Wier Guest

    try setting it in the code, when your event fires, then, at the end of the
    event try
    ControlName.Focus

    David Wier
    http://aspnet101.com
    http://iWritePro.com - One click PDF, convert .doc/.rtf/.txt to HTML with no
    bloated markup
     
    David Wier, Jul 8, 2008
    #2
    1. Advertisements

  3. Paul

    Paul Guest

    It works, thanks.
    --
    Paul G
    Software engineer.


     
    Paul, Jul 8, 2008
    #3
    1. Advertisements

Ask a Question

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

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.