3 Answers, 1 is accepted

In RadComboBox1_SelectedIndexChanged event handler you can access the grid dataitem using NamingContainer property of RadComboBox and then access the corresponding cell in that row using Its ColumnUniqueName.Check out the following code below.
C#:
protected
void
RadComboBox1_SelectedIndexChanged(
object
sender, Telerik.Web.UI.RadComboBoxSelectedIndexChangedEventArgs e)
{
GridDataItem item = (GridDataItem)(sender
as
RadComboBox).NamingContainer;
item[
"LastName"
].Text =
"New Value"
;
}
ASPX:
<
telerik:RadGrid
ID
=
"RadGrid1"
runat
=
"server"
AutoGenerateColumns
=
"false"
AllowPaging
=
"True"
Skin
=
"Windows7"
AllowSorting
=
"True"
DataSourceID
=
"SqlDataSource1"
AutoGenerateDeleteColumn
=
"true"
AllowMultiRowSelection
=
"true"
>
<
MasterTableView
>
<
Columns
>
<
telerik:GridBoundColumn
DataField
=
"LastName"
HeaderText
=
"LastName"
UniqueName
=
"LastName"
>
</
telerik:GridBoundColumn
>
<
telerik:GridTemplateColumn
HeaderText
=
"GridTemplateColumn(sort)"
>
<
ItemTemplate
>
<
telerik:RadComboBox
runat
=
"server"
ID
=
"RadComboBox1"
EnableLoadOnDemand
=
"True"
DataTextField
=
"LastName"
DataValueField
=
"LastName"
AutoPostBack
=
"true"
HighlightTemplatedItems
=
"true"
Height
=
"140px"
Width
=
"100px"
DropDownWidth
=
"100px"
DataSourceID
=
"SqlDataSource1"
SelectedValue='<%#Bind("LastName")%>'
onselectedindexchanged="RadComboBox1_SelectedIndexChanged"></
telerik:RadComboBox
>
</
ItemTemplate
>
</
telerik:GridTemplateColumn
>
</
Columns
>
</
MasterTableView
>
</
telerik:RadGrid
>
Thanks,
Princy.

I have a similar, but more complex question. I have the following grid setup:
<telerik:RadGrid ID="RadGridProd" runat="server" ShowStatusBar="true" DataSourceID="ProdLine"
Width="850px" AllowPaging="True" AllowSorting="True" OnPreRender="RadGridProd_PreRender"
AutoGenerateColumns="False" onupdatecommand="RadGridProd_ItemUpdated"
ondeletecommand="RadGridProd_ItemDeleted"
oninsertcommand="RadGridProd_ItemInserted"
onitemcommand="RadGridProd_ItemCommand1"
OnItemDataBound="RadGridProd_ItemDataBound" GridLines="None"
Skin="Windows7">
<HeaderContextMenu EnableImageSprites="True" CssClass="GridContextMenu GridContextMenu_Default" Width="950px"></HeaderContextMenu>
<MasterTableView Name="MasterProd" AutoGenerateColumns="false" DataKeyNames="ProdLineID" GridLines="None" Width="100%" CommandItemDisplay="Top" EditMode="InPlace" TableLayout="Fixed">
The DataSource is an XML file that contains many columns, a couple are ProductID, Quantity, UnitPrice and Total (among others). Since I only store ProductID in the XML file, I only have an integer in this column. I have the following column definition for this Product column...
<
telerik:GridTemplateColumn HeaderText="Product" UniqueName="ProductName" ItemStyle-Width="125px">
<ItemTemplate>
<%#DataBinder.Eval(Container.DataItem, "ProductID")%>
</ItemTemplate>
<EditItemTemplate>
<telerik:RadComboBox ID="cmbProductName" runat="server"
DataSourceID="Products" SortExpression="ProductName" DataValueField="ProductID"
DataTextField="ProductName" DataField="ProductID" Width="120px" OnSelectedIndexChanging="PushProdData"
SelectedValue='<%#Bind("ProductID") %>'>
</telerik:RadComboBox>
</EditItemTemplate>
<HeaderStyle Width="150px" HorizontalAlign="Center"></HeaderStyle>
</telerik:GridTemplateColumn>
Notice that I have another datasource for the Product RadComboBox - this is from the Products SQL table - which contains ProductID, ProductName, UnitPrice, etc. The combobox displays the product name; however, I cannot get the DataBinder to show the ProductName - because it is not in the grid datasource. How can this be done? Can I bind this "non edit" grid column to the ProductName selected in the RadComboBox? I went with the RadComboBox instead of the GridDropDownColumn trying to get the next functionality to work - this data shows up correctly if I use a GridDropDownColumn.
Next, I want the UnitPrice column to be the UnitPrice of the selected ProductID from the RadComboBox - where the UnitPrice comes from the Products datasource of the RadComboBox instead of the Prodline datasource of the Grid. Can this be accomplished with a GridDropDownColumn?
Straight onto the questions:
Q: "The combobox displays the product name; however, I cannot get the DataBinder to show the ProductName - because it is not in the grid datasource. How can this be done?"
A: Since the ProductName column is not present in the Grid's source, you can not bind a grid column to it. The grid has its own DataSource set (the XML file ) and it can display only the values from it. However, as you have noted the GridDropDownColumn implements this functionality thanks to its separate data source.
Q: Next, I want the UnitPrice column to be the UnitPrice of the selected ProductID from the RadComboBox - where the UnitPrice comes from the Products datasource of the RadComboBox instead of the Prodline datasource of the Grid. Can this be accomplished with a GridDropDownColumn?
A: Same situation here - the UnitPrice column must be present in the grid's data source in order to display it. The GridDropDownColumn data source has the only purpose to provide data for the build in RadComboBox. You can not use this data source to bind the UnitPrice grid column because it will be bound to the grid's data source instead.
For more information about GridDropDownColumn, you can review the following help article:
Customize/Configure GridDropDownColumn
I hope this helps.
Kind regards,
Martin
the Telerik team