I've been trying to have my sliding zone load with the Tab hidden. This is proving difficult. I have tried putting javascript in the page to run when the page is rendered. That throws an error though, even when I put the script at the end of the page it runs before the controls are rendered on the page and throws a script error. This also happens when I register client script block at the end of the pageload server side.
The one thing that come the closest to working is calling the javascript in the OnClientLoad event of the RadSplitter. However, this throws a javascript error which I will note below. Everything works, everything, but I cannot have a javascript error on my page for the end user.
The Error is 'Object doesn't support this property or method.'
The debugger shows the error at this code in the page:
the highlighted error is at the end on
Any help is greatly appreciated.
The one thing that come the closest to working is calling the javascript in the OnClientLoad event of the RadSplitter. However, this throws a javascript error which I will note below. Everything works, everything, but I cannot have a javascript error on my page for the end user.
The Error is 'Object doesn't support this property or method.'
The debugger shows the error at this code in the page:
getHandler:
function
(b){
var
a=
this
._getEvent(b);
if
(!a||a.length===0)
return
null
;a=Array.clone(a);
return
function
(c,d){
for
(
var
b=0,e=a.length;b<e;b++)a[b](c,d)}}
the highlighted error is at the end on
a
[b](c,d)
Clearly this is not being thrown in the javascript I am using. Here is the code I am using.
<
telerik:RadSplitter
ID
=
"RadSplitter2"
runat
=
"server"
Height
=
"82px"
Width
=
"100%"
Orientation
=
"Horizontal"
VisibleDuringInit
=
"false"
Skin
=
"EPSS"
EnableEmbeddedSkins
=
"false"
OnClientLoad="javascript:TogglePaneTabVisibility('<%=SlidingPane.ClientID %>')"
>
function
TogglePaneTabVisibility(panelid)
{
var
slidingZone = $find(
"<%=szCR.ClientID %>"
);
var
pane = slidingZone.getPaneById(
"<%=SlidingPane.ClientID %>"
);
if
(pane.isTabDisplayed())
{
pane.hideTab();
}
else
{
pane.showTab();
}
}
Any help is greatly appreciated.