[]
        
(Showing Draft Content)

GrapeCity.Documents.Excel.Expressions.ParseContext

ParseContext Class

Represents options used when converting formula text to a FormulaSyntaxTree.

Use this class to supply parsing context for Parse(string, ParseContext), such as the formula location and whether references are interpreted in R1C1 style. The base row and base column are zero-based indexes.

Inheritance
ParseContext
Namespace: GrapeCity.Documents.Excel.Expressions
Assembly: DS.Documents.Excel.dll
Syntax
public class ParseContext
Public Class ParseContext
Examples
ParseContext context = new ParseContext();
context.BaseRow = 0;
context.BaseColumn = 0;
context.IsR1C1 = false;
FormulaSyntaxTree syntaxTree = FormulaSyntaxTree.Parse("a\\b", context);
SyntaxNode root = syntaxTree.Root;

Constructors

Name Description
ParseContext()

Creates an empty parse context.

Properties

Name Description
BaseColumn

Gets the 0-based column location of the formula.

This value is used by ParseContext when parsing formulas that depend on the formula's position, such as relative references.

BaseRow

Gets the 0-based row location of the formula.

IsR1C1

Gets or sets a value indicating whether references are interpreted in R1C1 style.

Use this property together with BaseRow and BaseColumn when the parse context is used for Parse(string, ParseContext). If this property returns true, formula references are parsed as R1C1-style references; otherwise, A1-style references are used.