Put spreadsheet formula (ex. "=SUM(A1:A10)") in specified cell

Dear Syncfuison Team,

I have to put spreadsheet formula in specified cell. 
I have tried to acheive it by using XLEdit updateCell() method but "=SUM(A1:A10)" is treated like string not like formula and
after method execution I can still see the formula string 
furthermore if I double click this cell and press enter spreadsheed starts treating it like the formula and returns proper value.
Is there any way to update this cell from the code?

Regards
Maciej

1 Reply

SI Silambarasan I Syncfusion Team February 12, 2018 09:56 AM UTC

Hi Maciej, 
 
Thank you for using Syncfusion products. 
 
We have checked your requirement ‘To update formula values programmatically’ and we would like to suggest you to use ‘XLEdit.updateCellValue()’ client-side method to achieve it in Spreadsheet. Please refer the below code example & sample. 
 
 
//... 
this.XLEdit.updateCellValue({ rowIndex: 0, colIndex: 2 }, "=SUM(A1:A10)"); 
 
 
 
 
 
Regards, 
Silambarasan 


Loader.
Up arrow icon