Hi,
I am implementing Iggrid in my Angular 2 project. i have a Cell called Weight and cell called Percentage, so my Percentage value depend on Weight.
For e.g. if i would enter 10 in Weight cell then same value should reflect in percentage cell on runtime. how can i implement this ?
Please find below screenshot
Thanks,
Yogesh
Hello Yogesh,
Thank you for contacting Infragistics!
You will want to use the editCellEnded to achieve this behavior. In the event if gives you the column key which you will check to see if it is your weight column that was just edited. It will also then tell you the new value and the id of the row being edited: http://www.igniteui.com/help/api/2016.2/ui.iggridupdating#events:editCellEnded
You can use that information to then call setCellValue on your percentage cell:http://www.igniteui.com/help/api/2016.2/ui.iggridupdating#methods:setCellValue
Hi Mike,
Thanks for a Reply ...
1). I have tried to implemented what you suggest , but totalamout column get reflected after i have click on Done, i need it to get reflect on percentage cell while i m entering value in Weight cell.
2).Another thing i want , how can i implement customer summary in iggrid , i want to calculate weighted unit price at the end of the row ,for that formula would be
sum of TotalAmount/Count of Carats
Please check the Below Screenshot
can you please help with this
yogesh
Thank you for the update. If that is the case you will want to setup an editor provider and handle the valueChanged of the editor:
https://www.igniteui.com/help/working-with-combo-editor-provider
http://www.igniteui.com/help/api/2016.2/ui.ignumericeditor#events:valueChanged
For the custom summary it sounds like you want to do that for each row. If that is the case you would do it in the same fashion of handling the value changed and then set the value of the cell you want as your summary.