Hi,
I'm not aware of such a book, but have you tried something like :
function refreshActiveTab(){
try{
var mySelectedTab = <cfoutput>'#url.selectedTab#'</cfoutput>
ColdFusion.Layout.selectTab("myTabs", mySelectedTab);
return;
}
catch(err){}
}
function addLoadEvent(func) {
var oldonload = window.onload;
if (typeof window.onload != 'function') {
window.onload = func;
} else {
window.onload = function() {
oldonload();
func();
}
}
}
addLoadEvent(refreshActiveTab);
Where "refreshActiveTab" should hold the needed disabletabs of yours..
I use this to do something else, but why shouldn't it work in your case...?
> Ok got a question for all the gurus out there. Is there a hidden book
> of knowledge on the subject of ColdFusion and Ext JS for version 8 of
> CF? One of the annoying things I am running into that I can live with
> but I just want to know why it happens is this. I am using <cflayout>
> in a tabbed layout. The target browser of the client is IE 6 [Can't
> change it, large corporate monster I'd sooner get a pardon from the
> president then them upgrading.]. When the page renders, the content
> renders first kind of in a stack down the screen way and then there is
> like a slight hiccup [flicker if you will] then all the tabs get
> rendered properly and the display is as intended. I am wondering if
> like in Flex there is some kind of creation complete event that fires
> off when all the data is done loading and then the browser is
> reloading everything into the tabbed interface.
>
> The reason I am asking that question is because it spawns from another
> thing I noticed. I was attempting to 'hide' one of the tabs depending
> on if a certain flag was flipped on or off. I was controlling this via
> inline javascript on the page. See code below:
>
> <cflayout name="DataContainer" type="tab" style="width:100%;
> height:100%;">
> <cflayoutarea name="Element1" title="Element1">
> <!--- Content Here --->
> <cflayoutarea>
> <cflayoutarea name="Element2" title="Element2">
> <!--- Content Here --->
> <cflayoutarea>
> <cflayoutarea name="Element3" title="Element3">
> <!--- Content Here --->
> <cflayoutarea>
> </cflayout>
> <!--- This is directly below the cflayout --->
> <cfif SESSION.UserBucket.UserAccess NEQ 1>
> <script>
> function disable_tabView(m,n){
> ColdFusion.Layout.disableTab(m,n);
> }
> disable_tabView('DataContainer','Comments');
> </script>
> </cfif>
> <!--- This code is abit further down the page but still after cflayout
> --->
> <input type="button" value="LightsOut"
> onclick="disable_tabView('DataContainer','Comments');"/>
>
> When this page loads there is a javascript error [down in the
> statusbar] thrown stating that there was an unhandled exception. Appon
> further inspection and running this in Firefox with Error Console
> plugin the error states: [Error: uncaught exception: ColdFusion.Layout.
> disableTab: Tab layout not found, id: DataContainer] which is strange
> because if I click the button I have on the page, guess what, the tab
> is disabled. This is leading me to believe that the whole flicker
> problem I described above is related. Maybe the flicker I see when the
> browser redraws the content in to the tabs on the screen is happening
> after my inline js fires off, in which case I am inclined to
> understand why my code is busted. If this is the case, then is there
> an event that fires off to let me know that the browser is done
> redrawing the content and then I can fire off the js function?
>
> This is not super important, just wanna know why this is not working.
>
> Brett
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Want to reach the ColdFusion community with something they want? Let them know
on the House of Fusion mailing lists
Archive:
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:327831
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe:
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4