SpreadsheetGear
MaxRecursions Property
See Also  Send Feedback
SpreadsheetGear Namespace > IWorkbookSet Interface : MaxRecursions Property

Gets or sets the maximum number of recursive calculations allowed when references to cells still needing calculation are detected during workbook set calculation.

Syntax

Visual Basic (Declaration) 
Property MaxRecursions As Integer
C# 
int MaxRecursions {get; set;}

Remarks

Recursion is used when a reference to a cell still needing calculation is detected during workbook set calculation, up to the maximum number of recursions allowed by the MaxRecursions property. When the maximum number of recursions is exceeded, a slower strategy will be employed to calculate these cells.

The default number of recursions allowed is 1024. This is high enough that the vast majority of workbooks will be calculated using recursion, and low enough that stack overflow exceptions are extremely rare (this property was made public two years after SpreadsheetGear was released in response to the first reported case of a stack overflow exception).

Some workbooks will generate stack overflow exceptions in environments with limited stack size available (such as some ASP.NET implementations which are limited to a stack size of 256K). Setting MaxRecursions to a smaller number will limit the amount of stack space used.

Some complex workbooks will calculate faster with higher MaxRecursions settings.

In most cases, the setting of MaxRecursions will have little or no effect after a workbook set is calculated the first time.

Requirements

Platforms: Windows 2000, Windows XP, Windows Vista, Windows Server 2003 and Windows Server 2008. SpreadsheetGear 2009 requires the Microsoft .NET Framework 2.0 and supports .NET 3.0 and .NET 3.5.

See Also

Copyright © 2003-2009 SpreadsheetGear LLC. All Rights Reserved.Help Powered by Innovasys   
SpreadsheetGear is a registered trademark of SpreadsheetGear LLC.
Microsoft, Microsoft Excel and Visual Studio are trademarks or registered trademarks of Microsoft Corporation.