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

RadPanes in Repeater

3 Answers 45 Views
Splitter
This is a migrated thread and some comments may be shown as answers.
Chris
Top achievements
Rank 1
Chris asked on 14 May 2012, 11:09 PM
Hi,

I'm not sure if what I'm doing is possible with the Splitter control, but it'd great if I could get some advice.

Basically, I'd like to be able include RadPane's inside a repeater item - so that each item would be 'resizable' in relation to the other items.

Here's my markup currently:

   <telerik:RadSplitter ID="splt" runat="server" Width="100%">              
<asp:Repeater ID="rptSplitter" runat="server" OnItemDataBound="rptSplitter_ItemDataBound">
<ItemTemplate>
<telerik:RadPane ID="pane" runat="server">
<asp:Label ID="lblText" runat="server" Text='<%# DataBinder.Eval(Container.DataItem,"From") %>'></asp:Label>
<telerik:RadGrid ID="gv" runat="server" AutoGenerateColumns="false">
<MasterTableView runat="server" DataKeyNames="ID">
<Columns>
<telerik:GridBoundColumn DataField="ConsignmentNo" HeaderText="Consignment" SortExpression="ConsignmentNo">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="Customer" HeaderText="Customer" SortExpression="Customer"></telerik:GridBoundColumn>
</Columns>
</MasterTableView>
</telerik:RadGrid>
</telerik:RadPane>
</ItemTemplate>
<SeparatorTemplate>
<telerik:RadSplitBar runat="server"></telerik:RadSplitBar>
</SeparatorTemplate>
</asp:Repeater>
 </telerik:RadSplitter>

But this code does not work - the page simply doesn't render anything. If I remove the RadSplitter, RadPane etc elements then the Repeater displays the items correctly. Any ideas?

3 Answers, 1 is accepted

Sort by
0
Dobromir
Telerik team
answered on 16 May 2012, 10:27 AM
Hi Chris,

RadSplitter does not support controls other than RadPane to be nested as direct children.

If I understand you correctly, you need to dynamically create the splitter's panes and their content based on some datasource. To do so you need to create and add the control on the server. Please take a look at the following help article to how to create and configure RadSplitter on the server:
http://www.telerik.com/help/aspnet-ajax/splitter-server-side-defining-structure.html

All the best,
Dobromir
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
Chris
Top achievements
Rank 1
answered on 16 May 2012, 04:28 PM
Many thanks for your reply,

I have indeed tried that but all the controls inside the RadPane's are lost on PostBack - this is an issue as each pane controls a RadGrid, and the user needs to be able to drag and drop between grids - so when the drop occurs and the server posts back, my RowDrop event doesn't fire and all my controls disappear. If I recreate them on postback, I will lose the details of the drag drop occurred.

Is there any possible way to do this or would I need to use another control?
0
Dobromir
Telerik team
answered on 17 May 2012, 02:15 PM
Hi Chris,

I tried to reproduce the described behavior but to no avail. Could you please open formal support ticket and provide sample fully runnable project reproducing the issue so we can examine and debug it locally?

For your convenience I have attached my test page, could you please modify it to a point where the problem occurs and send it back?

Greetings,
Dobromir
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.
Tags
Splitter
Asked by
Chris
Top achievements
Rank 1
Answers by
Dobromir
Telerik team
Chris
Top achievements
Rank 1
Share this question
or