Hi
Madhu,
Thank
you for contacting Syncfusion Support.
We have
analyzed your requirement and you can achieve your datagrid columns like in the
figure you attached by using GridUnBoundColumn and setting the
Expression=Quantity*Unit rate. And if you are dynamically changing the Quantity
or Unit rate values, then you need to set the property
LiveDataUpdateMode=”AllowDataShaping” for updating the Expression value.
Please find the code snippet in below:
Code
Snippet[XAML]:
<Grid Background=”{StaticResource ApplicationPageBackgroundThemeBrush}”>
<yncfusion:SfDataGrid AllowDraggingColumns=”True” AutoGenerateColumns=”False”
ColumnSizer=”Star” AllowEditing=”True”
ItemsSource=”{Binding Detailscollection}”
LiveDataUpdateMode=”AllowDataShaping”
AllowFiltering=”True”>
<yncfusion:SfDataGrid.Columns>
<yncfusion:GridUnBoundColumn Expression=”Quantity*Amount”
MappingName=”Total”/>
</yncfusion:SfDataGrid.Columns>
</yncfusion:SfDataGrid>
</Grid>
|
We have
prepared a sample based on your requirement. Please find the sample in the
attachments.
Please
let us know if this solution helps you.
Thanks,
Saravanan
C
Attachment:
UnBoundColumnExpression_61dcef73.zip