Hi,
I have a radgrid in which there are 5 columns. one of the column is gridtemplatecolumn in which the itemtemplate is a label and edititemtemplate is dropdownlist. Code is as given below:
<telerik:GridTemplateColumn DataField="GameId" HeaderText="Game Id" SortExpression="GameId" UniqueName="GameId">
<EditItemTemplate>
<telerik:RadComboBox ID="radGameId" runat="server">
<Items>
<telerik:RadComboBoxItem Text="1" Value="1" />
<telerik:RadComboBoxItem Text="2" Value="2" />
</Items>
</telerik:RadComboBox>
</EditItemTemplate>
<ItemTemplate>
<asp:Label ID="ltrlGameId" Text='<%# Eval("GameId") %>' runat="server"></asp:Label>
</ItemTemplate>
</telerik:GridTemplateColumn>
When I am setting the dropdown value as a controlparameter in the sqldatasource, the value is passed as NULL. Not sure why it is happening like this. update parameters(GameId) is as given below:
<UpdateParameters>
<asp:Parameter Name="Id" Type="String" />
<asp:ControlParameter Name="GameId" Type="Int32" ControlID="radGameId" PropertyName="SelectedValue" />
<asp:Parameter Name="IsBase" Type="Boolean" />
<asp:Parameter Name="CurrencyPairID" Type="String" />
<asp:Parameter Name="InvertFlag" Type="Boolean" />
</UpdateParameters>
Please let me know how to pass dropdownlist selected value as the parameter to GameId.
Thanks, Mahesh