ワークブックの数式計算モードの設定
Contents
[
Hide
]
Microsoft Excel では、数式の計算モード、つまり数式の計算方法を設定できます。次の 3 つの値があります。
- 自動 - 何かが変更されるたび、およびワークブックが開かれるたびに再計算します。
- データ テーブルを除いて自動 - 何かが変更されるたびに再計算しますが、データ テーブルは除外します。
- 手動 - ユーザーが F9 キーまたは CTRL + ALT + F9 キーを押して明示的に要求した場合、またはブックが保存された場合にのみ再計算します。
Microsoft Excel で数式計算モードを設定するには:
- 選択する数式その後計算オプション.
- いずれかのオプションを選択します。
Aspose.Cells を設定することもできます式計算モード使用してFormulaSettings.CalculationModeモード プロパティ。あなたはそれを割り当てることができますCalcModeType次のいずれかの値を持つ列挙型:
- CalcModeType.Automatic
- CalcModeType.AutomaticExceptTable
- CalcModeType.Manual
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// For complete examples and data files, please go to https://github.com/aspose-cells/Aspose.Cells-for-.NET | |
// The path to the documents directory. | |
string dataDir = RunExamples.GetDataDir(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); | |
// Create a workbook | |
Workbook workbook = new Workbook(); | |
// Set the Formula Calculation Mode to Manual | |
workbook.Settings.FormulaSettings.CalculationMode = CalcModeType.Manual; | |
// Save the workbook | |
workbook.Save(dataDir + "output_out.xlsx", SaveFormat.Xlsx); |