Click here to Skip to main content
16,010,544 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
<datagrid name="itemGrid" grid.row="5" grid.column="0" grid.columnspan="4" autogeneratecolumns="False" margin="0,25,0,5" grid.rowspan="2" canuserreordercolumns="False" canuserresizecolumns="False" canusersortcolumns="False" selectionunit="Cell" canuserresizerows="False">

<datagrid.columns>

<datagridtextcolumn header="Sr No." width="50">
<datagridtemplatecolumn header="Item" width="300">
<datagridtemplatecolumn.celltemplate>
<datatemplate>
<local:filteredcombobox x:name="FilteredComboBox1" itemssource="{Binding}" itemspanel="{DynamicResource ItemsTemplate}" xmlns:x="#unknown" xmlns:local="#unknown">



<datagridtextcolumn header="Quantity" width="100">
<datagridtextcolumn header="Unit Price" width="100">
<datagridtextcolumn header="Vat %" width="100">
<datagridtextcolumn header="Discount" width="100">
<datagridtextcolumn header="Sub-Total" width="170">

<comboboxitem>

Posted

1 solution

If you are using MVVM then.

1. Bind your collection with the observablecollection <model>
2. on the each class using the I notifyPropertyvchanged interface to add and update the model.
3. Every Time you add a item into the collection it will update the UI.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900