How to modify this sample http://demos.telerik.com/aspnet-ajax/splitter/examples/sp_enableresizedock/defaultcs.aspx to disable resizing then no sliding panes are docked/expanded ???
4 Answers, 1 is accepted
0
Hi Aleksandr,
There are two possible way to achieve the disable the resizing of the Pane, holding the SlidingZone.
Vesi
the Telerik team
There are two possible way to achieve the disable the resizing of the Pane, holding the SlidingZone.
- You could remove the Splitbar, so the resizing won't be possible at all:
<
telerik:RadSplitter
ID
=
"RadSplitter1"
runat
=
"server"
Height
=
"400"
Width
=
"700"
>
<
telerik:RadPane
ID
=
"LeftPane"
runat
=
"server"
Width
=
"22"
Scrolling
=
"None"
>
<
telerik:RadSlidingZone
ID
=
"SlidingZone1"
runat
=
"server"
Width
=
"22"
>
...
</
telerik:RadSlidingZone
>
</
telerik:RadPane
>
<
telerik:RadPane
ID
=
"MiddlePane"
runat
=
"server"
>
Main Pane</
telerik:RadPane
>
</
telerik:RadSplitter
>
- You could configure the MinWidth Property of the SlidingZone's parent Pane (the LeftPane), so it could not be resized:
<
telerik:RadSplitter
ID
=
"RadSplitter1"
runat
=
"server"
Height
=
"400"
Width
=
"700"
>
<
telerik:RadPane
ID
=
"LeftPane"
runat
=
"server"
Width
=
"22"
Scrolling
=
"None"
MaxWidth
=
"22"
>
<
telerik:RadSlidingZone
ID
=
"SlidingZone1"
runat
=
"server"
Width
=
"22"
>
...
</
telerik:RadSlidingZone
>
</
telerik:RadPane
>
<
telerik:RadSplitBar
ID
=
"RadSplitbar1"
runat
=
"server"
>
</
telerik:RadSplitBar
>
<
telerik:RadPane
ID
=
"MiddlePane"
runat
=
"server"
>
Main Pane</
telerik:RadPane
>
</
telerik:RadSplitter
>
I hope this information would be helpful for you.
Vesi
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
0
Pankratov
Top achievements
Rank 1
answered on 28 Mar 2013, 02:19 PM
Vesi
I don't need to disable resizing at all, only then all panes are coalapsed, if some of them docked or expanded resize must work...
I don't need to disable resizing at all, only then all panes are coalapsed, if some of them docked or expanded resize must work...
0
Accepted
Hi Aleksandr,
Thank you for the clarification.
In such case you will need to attach handlers to the SplidingPanes' OnClientDocked and OnClientUndocked events, where to reset the MaxWidth value of there parent RadPane. For instance, it could be achieved in a similar way:
Please, give it a try and let me know if I could be any further assistance.
Kind Regards,
Vesi
the Telerik team
Thank you for the clarification.
In such case you will need to attach handlers to the SplidingPanes' OnClientDocked and OnClientUndocked events, where to reset the MaxWidth value of there parent RadPane. For instance, it could be achieved in a similar way:
<
telerik:RadSplitter
ID
=
"RadSplitter1"
runat
=
"server"
Height
=
"400"
Width
=
"550"
>
<
telerik:RadPane
ID
=
"LeftPane"
runat
=
"server"
Width
=
"22"
Scrolling
=
"None"
MaxWidth
=
"22"
>
<
telerik:RadSlidingZone
ID
=
"SlidingZone1"
runat
=
"server"
Width
=
"22"
>
<
telerik:RadSlidingPane
ID
=
"Pane1"
Title
=
"Pane1"
runat
=
"server"
Width
=
"150"
OnClientDocked
=
"OnClientDocked"
OnClientUndocked
=
"OnClientUndocked"
>
...
</
telerik:RadSlidingPane
>
<
telerik:RadSlidingPane
ID
=
"Pane2"
Title
=
"Pane2"
runat
=
"server"
Width
=
"150"
OnClientDocked
=
"OnClientDocked"
OnClientUndocked
=
"OnClientUndocked"
>
...
</
telerik:RadSlidingPane
>
</
telerik:RadSlidingZone
>
</
telerik:RadPane
>
<
telerik:RadSplitBar
ID
=
"RadSplitbar1"
runat
=
"server"
>
</
telerik:RadSplitBar
>
<
telerik:RadPane
ID
=
"MiddlePane"
runat
=
"server"
>
Main Pane</
telerik:RadPane
>
</
telerik:RadSplitter
>
<
script
type
=
"text/javascript"
>
function OnClientDocked(sender, args) {
var splitter = $find("RadSplitter1");
var parentPane = $find("LeftPane");
parentPane.set_maxWidth(parseInt(splitter.get_width()));
}
function OnClientUndocked(sender, args
) {
var parentPane = $find("LeftPane");
parentPane.set_maxWidth(22);
}
</
script
>
Please, give it a try and let me know if I could be any further assistance.
Kind Regards,
Vesi
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
0
Pankratov
Top achievements
Rank 1
answered on 29 Mar 2013, 10:25 AM
It works, thx