I have a Grid, with a detail table. The Grid datasource has 3 fields, a LineUID, an ItemUID, and an ItemName, and the LineUID is listed in the DataKeyNames. The detail table displays serial numbers associated with that LineUID. On an insert to the detail table, the edit form needs to look up available serial numbers based on the ItemUID. Is there a way to:
A) define that the DetailTable GridBoundColumn DefaultInsertValue should be the value of one of the mastertable's columns? Something like
<telerik:GridBoundColumn DataField="RowItemUID" Visible=false DefaultInsertValue=(MasterTable.GetColumnValue("ItemUID"))
B) inside the DetailTableDataBind function set the DefaultInsertValue for a column to the value of a non-key value for the mastertable row? Something like
Dim
dataItem
As
GridDataItem =
DirectCast
(e.DetailTableView.ParentItem, GridDataItem)
Dim
itemColumn
As
DataColumn = e.DetailTableView.Columns.FindByUniqueName(
"RowItemUID"
)
itemColumn.DefaultValue = dataItem.GetColumnValue(
"ItemUID"
)