Analyzing your prompt, please hold on...
An error occurred while retrieving the results. Please refresh the page and try again.
Microsoft Excel allows you to set the formula calculation mode, that is, the way formulas are calculated. There are three possible values:
To set the formula calculation mode in Microsoft Excel:
Aspose.Cells also allows you to set the Formula Calculation Mode using FormulaSettings.GetCalculationMode() mode property. You can assign it the CalcModeType enumeration which has one of the following values:
#include <iostream>
#include "Aspose.Cells.h"
using namespace Aspose::Cells;
int main()
{
Aspose::Cells::Startup();
// Source directory path
U16String srcDir(u"..\\Data\\01_SourceDirectory\\");
// Output directory path
U16String outDir(u"..\\Data\\02_OutputDirectory\\");
// Path of output excel file
U16String outputFilePath = outDir + u"output_out.xlsx";
// Create a workbook
Workbook workbook;
// Set the Formula Calculation Mode to Manual
workbook.GetSettings().GetFormulaSettings().SetCalculationMode(CalcModeType::Manual);
// Save the workbook
workbook.Save(outputFilePath, SaveFormat::Xlsx);
std::cout << "Workbook saved successfully with manual calculation mode!" << std::endl;
Aspose::Cells::Cleanup();
}
Analyzing your prompt, please hold on...
An error occurred while retrieving the results. Please refresh the page and try again.