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
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Setting FormulaCell formula

Thread ID:





6246 Aug 6,2003 08:42 AM UTC Aug 13,2003 06:06 AM UTC WinForms 4
Tags: GridControl
Nick Pasko
Asked On August 6, 2003 08:42 AM UTC

How do i apply the formulas listed in GridFormulaEngine to my FormulaCells? Do i have to place some text there, or do i have to set its FormulaTag property, or do i have to bind it to a new instance of GridFormulaEngine? And, most important for me - HOW do I do this :) Thanks ahead!

Administrator [Syncfusion]
Replied On August 6, 2003 09:45 AM UTC

If you want cell 1,4 to be the sum of the cells (A1:C1), then you would set the Text property of cell 1,4 to be the formula. //make 1,4 a formula cell this.grid[1,4].CellType = "FormulaCell"; //set the formula this.grid[1,4].Text = "=SUM(A1:A3)"; So, in general, to programatically set a formula, you set the cell's style.Text property to be exactly what you would type into the cell.

Nick Pasko
Replied On August 7, 2003 12:42 AM UTC

Yes, thanks! :) Ummm.. I hope this won't bore you to the death, but.. regardless of myself assuming that I need to use "SUM", "AVG" etc. keywords to describe the fuction, probably keywords containing the last three characters form the GridFormulaEngine methods, I would still like to know EXACTLY which keywords do I need there. You gave me a hint about GridFormulaEngine's methods, could you please also give me a hint about these keywords? PS I hope that sentence is not TOO complicated, though i realize it IS, a little, maybe.. ;)

Administrator [Syncfusion]
Replied On August 7, 2003 05:38 AM UTC

If you look at the Syncfusion\Essential Suite\Grid\Samples\Quick Start\FormulaGrid sample, it lists all the current formulas that are part of the formula library shipped with the product. Also, in the Suite Class Reference, if you look at the methods in the GridFormulaEngine class, you will see a series of methods named ComputeXXXXXX. The XXXXXX are the keywords for the formula library entries.

Nick Pasko
Replied On August 13, 2003 06:06 AM UTC

Thank you very much, indeed!


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

Live Chat Icon For mobile
Live Chat Icon