We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: June 24, 2019).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

TabControlExt is not hiding active TabPageExt

Thread ID:





8388 Nov 4,2003 06:23 PM UTC Nov 5,2003 11:51 AM UTC WinForms 3
Tags: Tools
Administrator [Syncfusion]
Asked On November 4, 2003 06:23 PM UTC

Hi, I am using tab control ext. It has about 4 tab page exts. When I am on 2nd tab and try to set the tabVisible=false on the same tab, it removes the top tab header. But the tab page itself is still there. After that if I switch other tabs, it is hiding the tab page. To reproduce this bug goto XPTabs sample. Replace this method private void tab1button1_Click(object sender, System.EventArgs e) { tab1.TabVisible = false; } Run the sample. Click on the "Contact info" tab. Now click on Fetch info button. Notice that you still see the email, address, phone # etc. fields. It should hide this tab page even if it is visible. thanks, - Reddy

Arun Srinivasan [Syncfusion]
Replied On November 4, 2003 09:20 PM UTC

Hi Reddy, This happens because there are instances where users want to just hide the tab and not it's contents and hence this is the intended behaviour when you try to hide an active tab. You could do something like: this.tab1.TabVisible=false; this.tabControlExt1.SelectedTab = tab2; to do what you are looking for. Thanks Arun

Administrator [Syncfusion]
Replied On November 5, 2003 11:31 AM UTC

Arun, In one of our application windows we have about 5 tabs. When the user picks a menu item or clicks on a tooldbar buttons, some of the information in the window does not make sense at that point. So we hide couple of tabs (say tab 2 and tab3). If I am viewing tab2, when I click my toolbar button, it removes the tab from the tab strip. But the tab2-page and its controls are still visible. This is certainly not the behavior anybody would like with "TabVisible=false". According to your work around, we will have to check if the tab is selected, then select some other tab and then hide it. We don't do this kind of things for other controls. Why just for this? thanks, - Reddy

Arun Srinivasan [Syncfusion]
Replied On November 5, 2003 11:51 AM UTC

Hi Reddy, A better solution to do what you are looking for is to call the ValidateSelectedIndex() method as this will ensure that the current selected tab is not disabled or invisible. So doing: this.tab1.TabVisible=false; this.tabControlExt1.ValidateSelectedIndex(); should take care of this issue. Regards Arun


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

Live Chat Icon For mobile
Live Chat Icon