formulae celltype

Posted by: lier on 8 September 2017, 1:51 pm EST

  • Posted 8 September 2017, 1:51 pm EST

     i need to get the sum of all the values present in the farpoint spread, can i do it using the formulae celltype .if yes. how?

     kindly help

  • Replied 8 September 2017, 1:51 pm EST


    You may use the formula to achieve the desired behavior. To illustrate this, let us  assume we need to calculate the Total of Column 1 values on the last Row of Column1, then this can be set as follows:

    Dim myCol As FarPoint.Win.Spread.Column
    myCol = FpSpread1_Sheet1.Columns(1)

    considering there are 10 rows and last row will show result of the Sum formula. Likewise, you may apply formulas across the Spread. Hope it helps.Thanks

  • Replied 8 September 2017, 1:51 pm EST


    I am not sure what you want to do exactly. It sounds like you want ot sum all the values and put the result outside the Spread. The code given to you by Suresh shows how to use formulas, but that formula may not do what you expect it to. It will put a formula in every cell of column B that is the sum of the cell to it's left and the 9 cells under it as well. I believe Suresh meant to set the Formula property to Rows(9) instead of Columns(1). If you want the calculation to be outside of the Spread, you would need to use the CalcEngine of Spread to build the formula you want to calculate.

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels