When I place this code into the JS file clean and recompile the tabs dont show up at all. WHen I put it back the way it was they show up? Any one else have this problem?
-------------
Please: Don't forget to click "Mark as Answer" on the post that helped you. That way future readers will know which post solved your issue.
Thanks for this code guys, just what I needed and works fine in I.E. However in Firefox the disabled tabs don't change appearance, I made this minor mod to fix this:
I added the folowing lines to set_enabled to add and remove the ajax_tab_disabled class from the header::
set_enabled : function(value) {
if (value != this._enabled) {
this._enabled = value;
if (value)
Sys.UI.DomElement.removeCssClass(this._header, "ajax__tab_disabled");
else
Sys.UI.DomElement.addCssClass(this._header, "ajax__tab_disabled");
if (this.get_isInitialized()) {
if (!this._enabled) {
this._hide();
} else {
this._show();
}
}
this.raisePropertyChanged("enabled");
}
}
I must be still doing something wrong. I tried adding the line to the activate like this....
_activate : function() {
if (this._enabled) {
var elt = this.get_element();
Sys.UI.DomElement.setVisible(elt,
true);
Sys.UI.DomElement.addCssClass(this._tab,
"ajax__tab_active");
// added this line to make it visible
this._owner.get_element().style.visibility =
true;this.populate();
this._show();
}
},
_deactivate : function() {
if (this._enabled) {
// original lines below
var elt =
this.get_element();Sys.UI.DomElement.setVisible(elt,
false);
Alll the tabs dont show up? Anyone else having this happen?
-------------
Please: Don't forget to click "Mark as Answer" on the post that helped you. That way future readers will know which post solved your issue.
I have added the proper update code to Tabs.js like posted in this thread, and closed VS 2005 and reopened it. (Did this suffice to 'rebuild' the
.dll/Tabs.js?)
When I use the code: "TabContainer1.ActiveTab.Enabled =
False" , the tab that I called actually disappears.
When I use the code: "TabContainer1.Enabled = False" , all of the tabs are greyed out, but they still work/are clickable.
I need to be able to:
A.) Have only specific tabs greyed out.
and
B.) Have the greyed out tabs unclickable.
spafa9
Member
126 Points
112 Posts
Re: How to set a Tab in a Tabcontainer to disabled (but visible)
Nov 15, 2007 04:43 PM|LINK
When I place this code into the JS file clean and recompile the tabs dont show up at all. WHen I put it back the way it was they show up? Any one else have this problem?
Please: Don't forget to click "Mark as Answer" on the post that helped you. That way future readers will know which post solved your issue.
BGriffin_TPA
Member
489 Points
311 Posts
Re: How to set a Tab in a Tabcontainer to disabled (but visible)
Nov 29, 2007 07:22 PM|LINK
Zoetosis :
Good question!..I'm using 10920 and when I Tabcontainer1.enable=false
or PanelOnATab.enable=false...it greays out but is still active..[:(]
the ActiveTabChanged event still fires, giving me an unwanted postback..[:(]
Any input is apprciated..[cool]
Dr_Software
Member
7 Points
2 Posts
Re: How to set a Tab in a Tabcontainer to disabled (but visible)
Dec 03, 2007 11:12 PM|LINK
Hi,
Thanks for this code guys, just what I needed and works fine in I.E. However in Firefox the disabled tabs don't change appearance, I made this minor mod to fix this:
I added the folowing lines to set_enabled to add and remove the ajax_tab_disabled class from the header::
set_enabled : function(value) { if (value != this._enabled) { this._enabled = value; if (value) Sys.UI.DomElement.removeCssClass(this._header, "ajax__tab_disabled"); else Sys.UI.DomElement.addCssClass(this._header, "ajax__tab_disabled"); if (this.get_isInitialized()) { if (!this._enabled) { this._hide(); } else { this._show(); } } this.raisePropertyChanged("enabled"); } }Then I added the CSS class to the tabs.css:
DWC
P.Murugs
Member
4 Points
2 Posts
Re: How to set a Tab in a Tabcontainer to disabled (but visible)
Dec 10, 2007 07:05 AM|LINK
Me too facing the same issue.After updating the above source code,tabs dont show up at all.
Anyone knows what could be the cause.
P.Murugs
Member
4 Points
2 Posts
Re: How to set a Tab in a Tabcontainer to disabled (but visible)
Dec 10, 2007 08:56 AM|LINK
Adding this line
'this._owner.get_element().style.visibility = 'visible';' to _activate function solves that issue.
spafa9
Member
126 Points
112 Posts
Re: How to set a Tab in a Tabcontainer to disabled (but visible)
Jan 04, 2008 01:26 PM|LINK
I must be still doing something wrong. I tried adding the line to the activate like this....
_activate : function() { if (this._enabled) { var elt = this.get_element();Sys.UI.DomElement.setVisible(elt,
true); Sys.UI.DomElement.addCssClass(this._tab, "ajax__tab_active"); // added this line to make it visible this._owner.get_element().style.visibility = true;this.populate();
this._show();}
},
_deactivate : function() { if (this._enabled) { // original lines below var elt = this.get_element();Sys.UI.DomElement.setVisible(elt, false);}
Sys.UI.DomElement.removeCssClass(this._tab, "ajax__tab_active");},
Alll the tabs dont show up? Anyone else having this happen?
Please: Don't forget to click "Mark as Answer" on the post that helped you. That way future readers will know which post solved your issue.
FZero
Member
21 Points
32 Posts
Re: How to set a Tab in a Tabcontainer to disabled (but visible)
Jan 04, 2008 02:38 PM|LINK
I have added the proper update code to Tabs.js like posted in this thread, and closed VS 2005 and reopened it. (Did this suffice to 'rebuild' the .dll/Tabs.js? )
When I use the code: "TabContainer1.ActiveTab.Enabled = False" , the tab that I called actually disappears.
When I use the code: "TabContainer1.Enabled = False" , all of the tabs are greyed out, but they still work/are clickable.
I need to be able to:
A.) Have only specific tabs greyed out.
and
B.) Have the greyed out tabs unclickable.
Any help on achieving this would be appreciated!
TIA!
- S
Tabs ajax tab container disable
www.fightingzero.com
BGriffin_TPA
Member
489 Points
311 Posts
Re: How to set a Tab in a Tabcontainer to disabled (but visible)
Jan 06, 2008 09:11 PM|LINK
I don't know what to say..my Jscript is not great, but I know someone who's is,
but he's not gonna do it for free.. [:(] I can't really help..if I could, I would..[:S]
we need to find somebody in MS who does this..I have been so busy with other
things, I haven't had time to check out the fix myself.
Regards,
B.Griffin [cool]
zoetosis
Member
265 Points
119 Posts
Re: How to set a Tab in a Tabcontainer to disabled (but visible)
Jan 14, 2008 01:36 PM|LINK
zoetosis
Member
265 Points
119 Posts
Re: How to set a Tab in a Tabcontainer to disabled (but visible)
Jan 14, 2008 01:36 PM|LINK
Whereabouts within the function should this line be added?