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

Making a Tab Invisible in the TabControl

Thread ID:

Created:

Updated:

Platform:

Replies:

29958 Jun 8,2005 08:46 AM UTC Jun 9,2005 06:42 PM UTC WinForms 2
loading
Tags: Tools
Nick Zdunic
Asked On June 8, 2005 08:46 AM UTC

I''m using the tabcontrol which has 4 tabs. In some instance when the form loads I have code which is enacted to make the first tab invisible, by setting TabVisible to false. When this code is used, the tab dissappears, but the next tab which should be visible partly hidden by a panel which looks like the remnants of the first tab. Clicking on the tab, forces a refresh and I see the contents of the tab. See the attached Word Document for examples. TabDisplayError_4233.zip

Nick Zdunic
Replied On June 9, 2005 03:04 AM UTC

So - is there a way to prevent this from happening? >I''m using the tabcontrol which has 4 tabs. > >In some instance when the form loads I have code which is enacted to make the first tab invisible, by setting TabVisible to false. > >When this code is used, the tab dissappears, but the next tab which should be visible partly hidden by a panel which looks like the remnants of the first tab. > >Clicking on the tab, forces a refresh and I see the contents of the tab. > >See the attached Word Document for examples. > > > >TabDisplayError_4233.zip > >

Administrator [Syncfusion]
Replied On June 9, 2005 06:42 PM UTC

Hi Nick, This problem is occuring because you''re hiding the currently selected tab without changing the selection. To avoid this, please use something similar to the following code snippet after setting the tab visibility: foreach (TabPageAdv page in this.tabControlAdv1.TabPages) { if (page.TabVisible) { this.tabControlAdv1.SelectedTab = page; break; } } Regards, Gregory Austin Syncfusion Inc.

CONFIRMATION

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.

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

;