TabControl selecting tab page with Button * Locked

Do you need something made? then ask in here.
Forum rules
Please LOCK your topics once you have found the solution to your question so we know you no longer require help with your query.
7 posts Page 1 of 1
Contributors
User avatar
tvs praveen
Top Poster
Top Poster
Posts: 205
Joined: Tue Dec 08, 2009 6:20 am

Hi, Now i want to make a stuff using Button and TabControl, I mean add 1 TabCOntrol and 1 Button

Now add 2 TabPages in TabControl, Now if click the Button1 want to make to jump TabControl to TabPage2

How i want to make it??

I want to know it to make TabControl`s TabPages Buttons with my custom buttons `cos i din`t like default TabControl`s TabPages buttons

- Kindly :)

- Tvs Praveen wahooo;

Now i got help from Lewis! wahooo;

To know read it below, Posted by Lewis :D
Last edited by tvs praveen on Sat Feb 20, 2010 12:10 am, edited 1 time in total.
Lewis
Coding God
Coding God
Posts: 1564
Joined: Sun Dec 20, 2009 2:12 pm

Hello,
If you are navigating to Tab2 ( The name )
TabControl1.SelectedTab = TabControl1.TabPages.Item("Tab2")

Thanks,
Lewis
Image
User avatar
Nery
Co-Admin Moderator
Co-Admin Moderator
Posts: 1117
Joined: Mon Sep 07, 2009 8:11 pm

If you have 3 TabPages in a TabControl:

To Select the second tab:
Code: Select all
TabControl1.SelectedTab = TabControl1.TabPages.Item(1)
To Select the third tab:
Code: Select all
TabControl1.SelectedTab = TabControl1.TabPages.Item(2)
To Select the first tab:
Code: Select all
TabControl1.SelectedTab = TabControl1.TabPages.Item(0)
The first tab is always "0" (TabIndex = TabNumber - 1)
User avatar
tvs praveen
Top Poster
Top Poster
Posts: 205
Joined: Tue Dec 08, 2009 6:20 am

lewisfroom wrote:
Hello,
If you are navigating to Tab2 ( The name )
TabControl1.SelectedTab = TabControl1.TabPages.Item("Tab2")

Thanks,
Lewis
Thanks a lot Lewis, I love you!!!!! wahooo;

A great help!!!!!!!!!!!!!!!!!!!111 :D :D :D wahooo; wahooo; wahooo;

- Tvs Praveen
User avatar
Nery
Co-Admin Moderator
Co-Admin Moderator
Posts: 1117
Joined: Mon Sep 07, 2009 8:11 pm

tvs praveen wrote:
lewisfroom wrote:
Hello,
If you are navigating to Tab2 ( The name )
TabControl1.SelectedTab = TabControl1.TabPages.Item("Tab2")

Thanks,
Lewis
Thanks a lot Lewis, I love you!!!!! wahooo;

A great help!!!!!!!!!!!!!!!!!!!111 :D :D :D wahooo; wahooo; wahooo;

- Tvs Praveen

And Nery >_<
Lewis posted while I was writting my post dunnno;
User avatar
hungryhounduk
VIP - Site Partner
VIP - Site Partner
Posts: 2870
Joined: Mon Jul 27, 2009 11:58 am

***Please Give thanks for these HELPFULL Posts***
Image
User avatar
Nery
Co-Admin Moderator
Co-Admin Moderator
Posts: 1117
Joined: Mon Sep 07, 2009 8:11 pm

Topic Locked - Solved
7 posts Page 1 of 1
Return to “Tutorial Requests”