Windows Form Tab Control - Selecting the tabpages.

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • lotus18
    Contributor
    • Nov 2007
    • 865

    Windows Form Tab Control - Selecting the tabpages.

    Hi

    How to switch to a certain tab page? I tried the focus and select method (with the name of the tabpage) but nothing happens.

    Rey Sean
  • DrBunchman
    Recognized Expert Contributor
    • Jan 2008
    • 979

    #2
    It depends which sort of tab are you using (Windows forms, AJAX tab panel etc) ?

    For example the AJAX tab panel has an ActiveTabIndex property which you can set.

    Dr B

    Comment

    • lotus18
      Contributor
      • Nov 2007
      • 865

      #3
      I'm using Windows forms

      Rey Sean

      Comment

      • DrBunchman
        Recognized Expert Contributor
        • Jan 2008
        • 979

        #4
        Then you can use
        Code:
         Me.TabControl1.SelectedTab = Me.TabPage1
        Hope this helps,

        Dr B

        Comment

        • lotus18
          Contributor
          • Nov 2007
          • 865

          #5
          Originally posted by DrBunchman
          Then you can use
          Code:
           Me.TabControl1.SelectedTab = Me.TabPage1
          Hope this helps,

          Dr B
          Thanks Dr. B : )


          Rey Sean

          Comment

          Working...