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

Binding RadComboBox inside RadGrid

2 Answers 200 Views
ComboBox
This is a migrated thread and some comments may be shown as answers.
Ambuj
Top achievements
Rank 1
Ambuj asked on 31 Jul 2012, 02:29 PM
Hi,

I am using RadComboBox inside Radgrid like below 
<telerik:GridTemplateColumn UniqueName="MyColumn" HeaderText="MyColumn">
                       <ItemTemplate>
                           <telerik:RadComboBox ID="MyComboBox" runat="server">
                               <ItemTemplate>
                                   <asp:CheckBox ID="chkBoxID" runat="server" />
                                   <asp:Label ID="lblMyLabel" runat="server" AssociatedControlID="chkBoxID">
                                   </asp:Label>
                               </ItemTemplate>
                           </telerik:RadComboBox>
                       </ItemTemplate>
                   </telerik:GridTemplateColumn>

As I am using Telerik.Web.UI dll with version (2009.1.311.35).

1) I have to bind it with some data source when I load the RadGrid,
how we can iterate through grid and bind each combo box with the desire collection ? 

2) When user click on Save button in page I have to store all the values which are checked in the combo box ? so how can I retrieve back when I save the page.??

how can I do on which event?

Thanks,
Ambuj

2 Answers, 1 is accepted

Sort by
0
Ambuj
Top achievements
Rank 1
answered on 02 Aug 2012, 08:33 AM
Any support for issue?
0
Nencho
Telerik team
answered on 02 Aug 2012, 03:18 PM
Hello Ambuj,

In order to achieve the desired functionality, please review our help article, describing how to implement and use RadComboBox inside RadGrid. Also you could see the demo about the same functionality here. In the example given for the demo is implemented the functionality, which is suitable for the desired scenario. In the OnItemDataBoundHandler you could bind the values to the RadComboBox and with a similar approach you could get the selected value in the OnClickHandler of the Save button.


All the best,
Nencho
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
ComboBox
Asked by
Ambuj
Top achievements
Rank 1
Answers by
Ambuj
Top achievements
Rank 1
Nencho
Telerik team
Share this question
or