Results 1 to 13 of 13

Thread: [RESOLVED] Do panels mess up Focus for other controls?

Threaded View

  1. #12

    Thread Starter
    KrisSiegel.com Kasracer's Avatar
    Join Date
    Jul 2003
    Location
    USA, Maryland
    Posts
    4,985

    Re: Do panels mess up Focus for other controls?

    Quote Originally Posted by Mike Hildner
    Urgh. Have you tried this? I don't think you understand the issue. Whenever I click on a control that's within some container, the tab order business works just fine. The real issue is resetting which container control is the first tab.

    Mike
    The first one would be all zeros.

    So your treeview would be the first tab. If you want to reset it, then simply changed the TabIndex property of it. If you have controls on other containers (like a panel), then they automatically have a higher base index, sort to speak.

    Let's say you have the following:

    The first textbox is on a panel. Then the center textbox is by itself with the buttons on its own panel.

    Right now, the first textbox will get focus.

    If I want to change it so the button first gets focus, I can't change it's TabIndex to be 0 because it's already 0. I have to change the panel's tabindex that contains the button (which is 2, hence the "2.0" and "2.1" over the buttons). If I change that panel to 0, then I can change the order in which things happen and now the button becomes first:


    I hope I explained that right.
    Attached Images Attached Images   
    KrisSiegel.com - My Personal Website with my blog and portfolio
    Don't Forget to Rate Posts!

    Free Icons: FamFamFam, VBCorner, VBAccelerator
    Useful Links: System.Security.SecureString Managed DPAPI Overview Part 1 Managed DPAPI Overview Part 2 MSDN, MSDN2, Comparing the Timer Classes

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width