Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
600
Can't seem to disable a tab when EnableAjax="true"
posted

We want to enable/disable all the tabs except the one the user is working on, based on conditions at runtime.

To simply illustrate the problem we're having, I created a webtab with a button on Tab[0]. In the Click event handler for the button, I coded

WebTab1.Tabs[1].Enabled = false;

When WebTab1.PostBackOptions.EnableAjax is set to false, this works; when set to true, it does not. I tried setting all the various other PostBackOptions, and I tried this:

 WebTab1.Tabs[1].GetUpdatePanel(true).Update();

to manually force a refresh. I also look for other properties or methods of the webtab and the contenttabitem classes, but nothing looked promising.

It seems I can disable controls inside the ConentPanes of the tabs just fine, but I cannot affect the webtab itself or the tabs collection.

Can anyone help? Thanks.

-BillyB