Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
15
XamDataGrid : Dynamic Column with two controls( Button, TextBox) not firing edit event
posted

I Have a XamDataGrid and i am adding dynamic columns .

Able to add the columns but when i try edit the text in the column it is not firing DatGrid edit event

Please help me on how to trigger fire event when enter data in text box

Grid Design

<igDP:XamDataGrid Grid.Row="3" Name="SubmissionGrid" Margin="5,5,5,5" Style="{StaticResource EventCreationXamDGStyle}" RecordsDeleting="SubmissionGrid_RecordsDeleting"
DataValueChanged="SubmissionGrid_DataValueChanged" EditModeStarting="SubmissionGrid_EditModeStarting" EditModeStarted="SubmissionGrid_EditModeStarted" EditModeEnding="SubmissionGrid_EditModeEnding" RecordAdded="SubmissionGrid_RecordAdded" KeyUp="SubmissionGrid_KeyUp" RecordsDeleted="SubmissionGrid_RecordsDeleted" RecordAdding="SubmissionGrid_RecordAdding" >
<igDP:XamDataGrid.Resources>
<Style TargetType="{x:Type igDP:CellValuePresenter}">
<Style.Triggers>
<DataTrigger Binding="{Binding RelativeSource={RelativeSource Self}, Path=Field.Name}" Value="Rec #">
<Setter Property="HorizontalContentAlignment" Value="Center"/>
</DataTrigger>
</Style.Triggers>
</Style>
</igDP:XamDataGrid.Resources>
<igDP:XamDataGrid.FieldLayoutSettings>
<igDP:FieldLayoutSettings AllowAddNew="True" AllowDelete="True" AddNewRecordLocation="OnBottom" AutoGenerateFields="False" AutoArrangePrimaryFieldReservation="None"/>
</igDP:XamDataGrid.FieldLayoutSettings>
<igDP:XamDataGrid.FieldLayouts>
<igDP:FieldLayout>
<igDP:FieldLayout.Fields>
<igDP:UnboundField Name="deleteField" Width="40">
<igDP:UnboundField.Settings>
<igDP:FieldSettings  AllowResize="False" AllowGroupBy="False" AllowRecordFiltering="False" AllowSummaries="False"
   CellMaxWidth="20" CellValuePresenterStyle="{StaticResource deleteButtonforEventCreationStyle}"/>
</igDP:UnboundField.Settings>
</igDP:UnboundField>
</igDP:FieldLayout.Fields>
</igDP:FieldLayout>
</igDP:XamDataGrid.FieldLayouts>

</igDP:XamDataGrid>

Adding dynamic columns with below code

Here is the cellpresentervalue style