Free Support Forum - aspose.com

Aspose.cells Formula does not calculated

Hi Laurence,



I am working on the Excel build in formula RSQ. When aspose generated
excel file opens, it gives #NAME? instead of the R square number. Can
you please help?



Thank you


59 Dim excelapp As Aspose.Cells.Excel = New Aspose.Cells.Excel

60

61 Dim ws As Aspose.Cells.Worksheet

62 ws = excelapp.Worksheets(0)

63 Dim i As Int32 = 0

64 For i = 0 To 60

65 ws.Cells(i, 0).PutValue(i)

66 ws.Cells(i, 1).PutValue(i + 1)

67

68 Next

69 ws.Cells(0, 3).Formula = "=SUM(A1:A16)"

70 ws.Cells(0, 4).Formula = "=RSQ(A1:A61,B1:B61)"

71 excelapp.CalculateFormula()

72 MsgBox(ws.Cells(0, 3).DoubleValue & " , " & ws.Cells(0, 4).DoubleValue)

73

74

75 excelapp.Save("c:\hhhh.xls")

76 System.Diagnostics.Process.Start("c:\hhhh.xls")


Aspose.Cells formula calculation engine doesn’t support RSQ function yet. We will make it in the future release.

Thank you!!! BTW, do you have LINEST function in aspose.cells?




Yes. Please check http://www.aspose.com/Products/Aspose.Cells/Api/Aspose.Cells.Excel.CalculateFormula1.html .