This is a migrated thread and some comments may be shown as answers.

How to collapse RadSlidingPane programmatically through java script or code behind?

7 Answers 179 Views
Splitter
This is a migrated thread and some comments may be shown as answers.
Shirish
Top achievements
Rank 1
Shirish asked on 31 Jan 2017, 04:50 PM

Hello Telerik team,

I am trying to achieve collapsing RadSlidingPane programmatically in java script or on server side but no luck.

Here what I am exactly trying to achieve:
I am having a search criteria with Search button in RadSlidingPane & I want to collapse all search criteria when user hits a Search button (which is also in the RadSlidingPane). Everything else working perfectly fine.

I wan to do this using java script or on server side so please let me know how to do this. Also please let me know if you need any additional information.

Thanks in advance.

Regards
Shirish

 

 

7 Answers, 1 is accepted

Sort by
0
Vessy
Telerik team
answered on 01 Feb 2017, 12:25 PM
Hi Shirish,

You can programmatically collapse/expand a sliding pane by calling its parent SlidingZone  collapsePane() or expandPane() methods:
http://docs.telerik.com/devtools/aspnet-ajax/controls/splitter/client-side-programming/radslidingzone-object


Regards,
Vessy
Telerik by Progress
Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
0
Shirish
Top achievements
Rank 1
answered on 01 Feb 2017, 02:13 PM
Thanks Vessy. Could you please post a javascript example that will help me to understand as I didn't find any syntax for SlidingZone  collapsePane() or expandPane(). Thanks.
0
Shirish
Top achievements
Rank 1
answered on 01 Feb 2017, 02:38 PM

Hi Vessy,

I tried this & it's not working :-(

function CollapseSearch(sender, args) {                
        var slideZne = document.getElementById("Radslidingzone2");
        var spane = document.getElementById("RAD_SLIDING_PANE_TAB_Radslidingpane4");
        slideZne.collapsePane(spane.id);

    }

Please let me know.

 

Thanks again.

 

Regards
Shirish

0
Accepted
Vessy
Telerik team
answered on 02 Feb 2017, 04:14 PM
Hi Shirish,

The suggested methods are part of the client-side API of the RadSlidingZone object, so you will need to get reference to it, instead of its html element in order to use them:
$find("RadSlidingZone2").collapsePane("Radslidingpane4")

I would advice that you examine the following article:
http://docs.telerik.com/devtools/aspnet-ajax/controls/splitter/client-side-programming/overview

Regards,
Vessy
Telerik by Progress
Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
0
Shirish
Top achievements
Rank 1
answered on 02 Feb 2017, 07:53 PM

Thanks Vessy perfect. It's working fine now. Thanks again.

Regards
Shirish

0
Vessy
Telerik team
answered on 03 Feb 2017, 11:41 AM
Hi,

I am glad I managed to help, Shirish - let us know should any further questions on this matter arise.

Regards,
Vessy
Telerik by Progress
Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
0
Justin
Top achievements
Rank 2
answered on 27 Mar 2018, 07:43 PM

+1 Vessy.

Just stumbled onto a similar need. Short, concise, and spot on. Much obliged.

Tags
Splitter
Asked by
Shirish
Top achievements
Rank 1
Answers by
Vessy
Telerik team
Shirish
Top achievements
Rank 1
Justin
Top achievements
Rank 2
Share this question
or