Can tab pages in a tab control can be individually enabled or disabled?
85 pts.
0
Q:
Can tab pages in a tab control can be individually enabled or disabled?
In my project developed using VB.NET 2005 there is a tab control with 4 tab pages. I need to call a method which will enable/disable those tab pages according the some boolean values referring to each tab page. For example if boolean value 1 is true the tab page 1 is enabled and users can operate it. 

I tried this on code but there's no Enabled property for tab pages. So is it possible in an alternative way? If it's possible how?



Software/Hardware used:
VB.NET 2005
ASKED: Aug 19 2009  6:06 AM GMT
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
0
29820 pts.
0
A:
 RATE THIS ANSWER
0
Click to Vote:
  •   0
  •  0
  • AddThis Social Bookmark Button
I don't know of a way to disable tabs, but you could remove them from the tab pages collection and add them back as needed.

Something like this:

        'Store the tab in a variable before removing it
some_page = TabControl1.TabPages(0)
'Remove it
TabControl1.TabPages.Remove(TabControl1.TabPages(0))


        'Insert the tab into the collection.  This will insert it into the first position
'If the tab order is not important, you could use the Add method instead
TabControl1.TabPages.Insert(0, some_page)
Last Answered: Aug 19 2009  8:09 AM GMT by Carlosdl   29820 pts.
0
0
Discuss This Answer:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _



_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

Muhammadalam   10 pts.  |   Nov 7 2009  11:45AM GMT

we have 4 tabpages in our mdi child form1. we want to click on main form btton then the control transfer to the tab page2 on child form.how we do that ?

 
0