Hi,
I have 2 questions about the GridView's CellEditTemplate when it comes to dynamic data binding.
My coding:
1. RadGridView control (AutoGenerateColumns = "False")
2. CellEditTemplate which has to be assigned dynamically in the code:
Question 1: With 'Text="{Binding InputString2}"' I bind to a particular column. I want to have that binding dynamically handled: for each column that uses that CellEditTemplate the data binding should work.
Question 2: In the CellEditTemplate I have a AutoCompleteBox. At the moment, it is not writing back the selected value from the AutoCompleteBox into the column that is in edit mode.
Thanks for any hints.
Phil
I have 2 questions about the GridView's CellEditTemplate when it comes to dynamic data binding.
My coding:
1. RadGridView control (AutoGenerateColumns = "False")
2. CellEditTemplate which has to be assigned dynamically in the code:
<
UserControl.Resources
>
<
DataTemplate
x:Key
=
"cellEditTemplate"
>
<
sdk:AutoCompleteBox
Name
=
"autoCompBox"
IsTextCompletionEnabled
=
"False"
FilterMode
=
"Contains"
Populating
=
"AutoCompleteBox_Populating"
MinimumPrefixLength
=
"3"
IsDropDownOpen
=
"True"
Text
=
"{Binding InputString2}"
/>
</
DataTemplate
>
</
UserControl.Resources
>
// generate the columns in the code
GridViewDataColumn col = new GridViewDataColumn();
...
col.CellEditTemplate = Resources["cellEditTemplate"] as DataTemplate;
Question 1: With 'Text="{Binding InputString2}"' I bind to a particular column. I want to have that binding dynamically handled: for each column that uses that CellEditTemplate the data binding should work.
Question 2: In the CellEditTemplate I have a AutoCompleteBox. At the moment, it is not writing back the selected value from the AutoCompleteBox into the column that is in edit mode.
Thanks for any hints.
Phil