We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Formulas with Virtual Grid ..

I see the databoundgrid example with formulas but i am trying to figure out if i need to store both the formula and do the calculation on my own. If i use formulas with a virtual grid (queryCellInfo & SaveCellInfo) does the grid take care of the calculation dependancy since i am giving formulas or do i have to manage that myself. Also, when SaveCellInfo gets called, how do i know if a formula was enterer or a values was entered. thks, ak

1 Reply

AD Administrator Syncfusion Team November 22, 2005 08:56 AM UTC

The grid will take care of the calculation dependencies. What you need to do is anytime e.Style.FormulaTag is non-null in SaveCellInfo, then save it in a hashtable (or something???) mapped to the cell at e.RowIndex and e.ColIndex. Then in your QueryCellInfo, for the passed in e.RowIndex and e.ColIndex, you check if there is an entry for the cell at this row and column in your hashtable. If there is, then you set this to e.Style.FormulaTag. Here is a minimal sample. http://www.syncfusion.com/Support/user/uploads/GC_Virt_Formulas_40deb4bf.zip

Loader.
Live Chat Icon For mobile
Up arrow icon