I’m John C Bland II

Husband, Father, Tech Author, Deacon.
Founder of Katapult Media, and full-stack polyglot developer.
Political Free Agents Podcast Host.

I create. I launch.

YouTube Channel

I post regular fun on YouTube like me playing the bass and anything else I find fun. 

Get Something Built

All project work goes through Katapult Media. Business is open. Let’s chat.

Where are you?

I’ve tried numerous things to get the tab to refresh. First off I was looking at Ext 2.0 docs but I didn’t realize it until I did a dump on the _ColdFusion.Layout.getTabLayout(“tabs”).getActiveTab()_ and noticed a method not mentioned on the docs. Oops…my bad! 😉

So…instead of just bashing CF8’s attempt at UI Controls via Ajax I figured I’d ask anyone listening.

bq. How do you refresh the active tab dynamically?

Before you answer, let me clarify. I have N number of tabs and inside this particular tab I open a _CFWindow_ (a few gripes about this too) which does some updating and when done I need the selected tab to refresh the contents so it properly shows the latest and greatest info.

Here is what I found to work (and all that worked):

bq. function refreshActiveTab(){
var activeID = ColdFusion.Layout.getTabLayout(“tabs”).getActiveTab().id;
ColdFusion.Layout.hideTab(“tabs”, activeID);
ColdFusion.Layout.showTab(“tabs”, activeID);
ColdFusion.Layout.selectTab(“tabs”, activeID);

That’s quite a sucky way to do it, IMO. The user doesn’t see the hide/show…at least in FF. In IE7 the modal background has no alpha (which looks crappy) so I can’t see it anyway.

Either way, after my trials tonight it merely validates my thoughts on CF’s Ajax UI Controls: they need a lot of work! I’ll rant later but the CF Ajax binding is SWEET (lacking a couple things but still sweet). I just want to see the UI controls come up to a really professional level.