Retaining Selection of JSF Tabbed Panels
I have the following function which is supposed to display my SECOND tab panel on body load of the page:
function setPane1()
{
panel = ODCRegistry.getElementById('tabbedPanel1','1');
panel.restoreUIState('bfpanel2');
}
<BODY onload="setPane1();">
My tab panels are something liek this:
<odc:tabbedPanel id="tabbedPanel1" width="100%"
slantActiveRight="4" styleClass="tabbedPanel" showTabs="true"
slantInactiveRight="4" variableTabLength="false"
showBackNextButton="false" height="100%" >
<odc:bfPanel id="bfpanel1" name="My First Tab Panel"
showFinishCancelButton="false" >
//content of tabpanel 1
</odc:bfPanel>
<odc:bfPanel id="bfpanel2" name="My Second Tab Panel"
showFinishCancelButton="false">
//Content of tabpanel2
</odc:bfPanel>
</odc:bfPanel>
<f:facet name="back">
<hx:commandExButton type="submit" value="< Back"
id="tabbedPanel1_back" style="display:none"></hx:commandExButton>
</f:facet>
<f:facet name="next">
<hx:commandExButton type="submit" value="Next >"
id="tabbedPanel1_next" style="display:none"></hx:commandExButton>
</f:facet>
<f:facet name="finish">
<hx:commandExButton type="submit" value="Finish"
id="tabbedPanel1_finish" style="display:none"></hx:commandExButton>
</f:facet>
<f:facet name="cancel">
<hx:commandExButton type="submit" value="Cancel"
id="tabbedPanel1_cancel" style="display:none"></hx:commandExButton>
</f:facet>
</odc:tabbedPanel>
However, the function to display the 2nd tab panel by default on body load is not working at all, and the first panel is displaying as usual.
Could someone please help?
Thanks in advance! :-)

