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: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Hide TabPages on TabBarSplitterControl

Thread ID:





93397 Mar 11,2010 01:50 PM UTC Apr 23,2010 09:35 AM UTC WinForms 5
Tags: Tools
Administrator [Syncfusion]
Asked On March 11, 2010 01:50 PM UTC

I'm trying to hide/show individual TabPages on a TabBarSplitterControl.

There is a Hide() method, and a Visible property, but neither seem to have any effect.

The samples hide/show by removing/re-inserting the tabPage, which is not at all what I want to do. Am I missing something? Many thanks.

(e.g. http://www.syncfusion.com/support/kb/646/How-do-I-hide-and-show-TabBarPages-in-a-TabBarSplitterControl-which-contains-a-grid)

Rajasekar B [Syncfusion]
Replied On March 12, 2010 03:29 PM UTC

Hi Sakkath,

Thanks for your interest in syncfusion product.

If you use this.tabBarSplitterControl1.TabBarPages.Remove(this.tabBarPage1), tabpage will only be removed from the collection and you can insert it whenever necessary using the below code


You can reuse that tabbarpage. Do you want the tabpage to be hidden but it should not be removed from the TabBarPages collection?


Administrator [Syncfusion]
Replied On March 22, 2010 09:59 AM UTC

Thanks for the reply.
Yes, I was trying to hide the sheet without removing from the collection.
E.g. I still want to process the sheet if it's hidden, but want the user to be able to hide it.
I could use two collections - one containing all pages, and another just those that are visible, but that seems like overkill. The other overhead with your method is remembering in what position the hidden pages should be added back in.

Ideally for me, setting visible to false, or calling hide(), should just skip the tab when drawing the control.
Am I stuck with the two collection solution for now?

Rajasekar B [Syncfusion]
Replied On March 23, 2010 03:18 PM UTC

Hi Sakkath,

Thanks for the update.

You can use the following line of code to hide the tab:

this.tabBarSplitterControl1.Bar.Tabs[i].HideButton = true;

To get the index of the particular tab, you can use the below line of code:

int i= this.tabBarSplitterControl1.TabBarPages.IndexOf(this.tabBarPage1);

Please let me know if you have any question.


Administrator [Syncfusion]
Replied On April 21, 2010 08:00 AM UTC

Hi Rajasekar
Thanks for the suggestion - it's been a while, I got caught up on other things...
The HideButton method certainly hides the button, but it isn't removed from the OnPaint, so it just leaves a big gap in the control.
Any way around that? I just want something like Excel where you can Hide/Show sheets, but preferably without having to actually remove/insert pages from the collection

Rajadurai C [Syncfusion]
Replied On April 23, 2010 09:35 AM UTC

Hi Sakkath,

Thanks for your update.

With TabBarSplitterControl, currently we don't provide support to hide the tabbarpages. However, we have logged a feature request for the same.

We will implement this feature in our forthcoming new version releases or service pack releases. The feature implementation would also greatly depend on the factors such as product design, code compatibility and complexity.

Thank you for using Syncfusion Products.



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