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. Image for the cookie policy date
close icon

TabControl / disabling tab selection by clicking

I have a TabControl implemented and the selection of the active tab is controlled programatically using SelectedIndex = ...
The user should not be able to change the tabs by clicking on them. What I tried is to hide the tabs using TabVisible . But then all the controls in the tab content area are moving up.

Is there any possibility to disable the tab selection by clicking on it?

BR
Christoph

2 Replies

J. J.Nagarajan Syncfusion Team October 5, 2007 11:36 PM UTC

Hi Christoph ,

Thanks for your interest in Syncfusion products.

You can disable the selection of tabs by clicking on the tab. You have to handle the SelectedIndexChanging event of the TabControlAdv. Please refer to the following code snippet

[C#]

private void tabControlAdv1_SelectedIndexChanging(object sender, Syncfusion.Windows.Forms.Tools.SelectedIndexChangingEventArgs args)
{
args.Cancel = true;
}


Please use this code and let me know if this helps

Regards,
Nagaraj


CG Christoph Gasser October 14, 2007 09:32 AM UTC

Thank you very much. It' working fine.

Loader.
Live Chat Icon For mobile
Up arrow icon