ClosedXML Indicates that compiler support for a particular feature is required for the location where this attribute is applied. Initialize a new instance of The name of the compiler feature. If true, the compiler can choose to allow access to the location where this attribute is applied if it does not understand . The used for the ref structs C# feature. The used for the required members C# feature. Disables the built-in runtime managed/unmanaged marshalling subsystem for P/Invokes, Delegate types, and unmanaged function pointer invocations. The built-in marshalling subsystem has some behaviors that cannot be changed due to backward-compatibility requirements. This attribute allows disabling the built-in subsystem and instead uses the following rules for P/Invokes, Delegates, and unmanaged function pointer invocations: - All value types that do not contain reference type fields recursively (unmanaged in C#) are blittable - Value types that recursively have any fields that have [StructLayout(LayoutKind.Auto)] are disallowed from interop. - All reference types are disallowed from usage in interop scenarios. - SetLastError support in P/Invokes is disabled. - varargs support is disabled. - LCIDConversionAttribute support is disabled. Indicates which arguments to a method involving an interpolated string handler should be passed to that handler. Initializes a new instance of the class. The name of the argument that should be passed to the handler. may be used as the name of the receiver in an instance method. Initializes a new instance of the class. The names of the arguments that should be passed to the handler. may be used as the name of the receiver in an instance method. Gets the names of the arguments that should be passed to the handler. may be used as the name of the receiver in an instance method. Indicates the attributed type is to be used as an interpolated string handler. Reserved to be used by the compiler for tracking metadata. This class should not be used by developers in source code. Used to indicate to the compiler that a method should be called in its containing module's initializer. When one or more valid methods with this attribute are found in a compilation, the compiler will emit a module initializer which calls each of the attributed methods. Certain requirements are imposed on any method targeted with this attribute: - The method must be `static`. - The method must be an ordinary member method, as opposed to a property accessor, constructor, local function, etc. - The method must be parameterless. - The method must return `void`. - The method must not be generic or be contained in a generic type. - The method's effective accessibility must be `internal` or `public`. The specification for module initializers in the .NET runtime can be found here: https://github.com/dotnet/runtime/blob/master/docs/design/specs/Ecma-335-Augments.md#module-initializer Specifies that a type has required members or that a member is required. Used to indicate to the compiler that the .locals init flag should not be set in method headers. This attribute is unsafe because it may reveal uninitialized memory to the application in certain instances (e.g., reading from uninitialized stackalloc'd memory). If applied to a method directly, the attribute applies to that method and all nested functions (lambdas, local functions) below it. If applied to a type or module, it applies to all methods nested inside. This attribute is intentionally not permitted on assemblies. Use at the module level instead to apply to multiple type declarations. Base type for all platform-specific API attributes. Marks APIs that were obsoleted in a given operating system version. Primarily used by OS bindings to indicate APIs that should not be used anymore. Records the operating system (and minimum version) that supports an API. Multiple attributes can be applied to indicate support on multiple operating systems. Callers can apply a or use guards to prevent calls to APIs on unsupported operating systems. A given platform should only be specified once. Annotates a custom guard field, property or method with a supported platform name and optional version. Multiple attributes can be applied to indicate guard for multiple supported platforms. Callers can apply a to a field, property or method and use that field, property or method in a conditional or assert statements in order to safely call platform specific APIs. The type of the field or property should be boolean, the method return type should be boolean in order to be used as platform guard. Records the platform that the project targeted. Marks APIs that were removed in a given operating system version. Primarily used by OS bindings to indicate APIs that are only available in earlier versions. Annotates the custom guard field, property or method with an unsupported platform name and optional version. Multiple attributes can be applied to indicate guard for multiple unsupported platforms. Callers can apply a to a field, property or method and use that field, property or method in a conditional or assert statements as a guard to safely call APIs unsupported on those platforms. The type of the field or property should be boolean, the method return type should be boolean in order to be used as platform guard. An attribute used to indicate a GC transition should be skipped when making an unmanaged function call. Example of a valid use case. The Win32 `GetTickCount()` function is a small performance related function that reads some global memory and returns the value. In this case, the GC transition overhead is significantly more than the memory read. using System; using System.Runtime.InteropServices; class Program { [DllImport("Kernel32")] [SuppressGCTransition] static extern int GetTickCount(); static void Main() { Console.WriteLine($"{GetTickCount()}"); } } This attribute is ignored if applied to a method without the . Forgoing this transition can yield benefits when the cost of the transition is more than the execution time of the unmanaged function. However, avoiding this transition removes some of the guarantees the runtime provides through a normal P/Invoke. When exiting the managed runtime to enter an unmanaged function the GC must transition from Cooperative mode into Preemptive mode. Full details on these modes can be found at https://github.com/dotnet/runtime/blob/master/docs/coding-guidelines/clr-code-guide.md#2.1.8. Suppressing the GC transition is an advanced scenario and should not be done without fully understanding potential consequences. One of these consequences is an impact to Mixed-mode debugging (https://docs.microsoft.com/visualstudio/debugger/how-to-debug-in-mixed-mode). During Mixed-mode debugging, it is not possible to step into or set breakpoints in a P/Invoke that has been marked with this attribute. A workaround is to switch to native debugging and set a breakpoint in the native function. In general, usage of this attribute is not recommended if debugging the P/Invoke is important, for example stepping through the native code or diagnosing an exception thrown from the native code. The runtime may load the native library for method marked with this attribute in advance before the method is called for the first time. Usage of this attribute is not recommended for platform neutral libraries with conditional platform specific code. The P/Invoke method that this attribute is applied to must have all of the following properties: * Native function always executes for a trivial amount of time (less than 1 microsecond). * Native function does not perform a blocking syscall (e.g. any type of I/O). * Native function does not call back into the runtime (e.g. Reverse P/Invoke). * Native function does not throw exceptions. * Native function does not manipulate locks or other concurrency primitives. Consequences of invalid uses of this attribute: * GC starvation. * Immediate runtime termination. * Data corruption. Any method marked with can be directly called from native code. The function token can be loaded to a local variable using the address-of operator in C# and passed as a callback to a native method. Methods marked with this attribute have the following restrictions: * Method must be marked "static". * Must not be called from managed code. * Must only have blittable arguments. Optional. If omitted, the runtime will use the default platform calling convention. Supplied types must be from the official "System.Runtime.CompilerServices" namespace and be of the form "CallConvXXX". Optional. If omitted, no named export is emitted during compilation. A class that represents nullability info The of the member or generic parameter to which this NullabilityInfo belongs The nullability read state of the member The nullability write state of the member If the member type is an array, gives the of the elements of the array, null otherwise If the member type is a generic type, gives the array of for each type parameter An enum that represents nullability state Nullability context not enabled (oblivious) Non nullable value or reference type Nullable value or reference type Provides APIs for populating nullability information/context from reflection members: , , and . Populates for the given . If the nullablePublicOnly feature is set for an assembly, like it does in .NET SDK, the private and/or internal member's nullability attributes are omitted, in this case the API will return NullabilityState.Unknown state. The parameter which nullability info gets populated If the parameterInfo parameter is null Populates for the given . If the nullablePublicOnly feature is set for an assembly, like it does in .NET SDK, the private and/or internal member's nullability attributes are omitted, in this case the API will return NullabilityState.Unknown state. The parameter which nullability info gets populated If the propertyInfo parameter is null Populates for the given . If the nullablePublicOnly feature is set for an assembly, like it does in .NET SDK, the private and/or internal member's nullability attributes are omitted, in this case the API will return NullabilityState.Unknown state. The parameter which nullability info gets populated If the eventInfo parameter is null Populates for the given If the nullablePublicOnly feature is set for an assembly, like it does in .NET SDK, the private and/or internal member's nullability attributes are omitted, in this case the API will return NullabilityState.Unknown state. The parameter which nullability info gets populated If the fieldInfo parameter is null Specifies that the method or property will ensure that the listed field and property members have not- values. Gets field or property member names. Initializes the attribute with a field or property member. The field or property member that is promised to be not-null. Initializes the attribute with the list of field and property members. The list of field and property members that are promised to be not-null. Specifies that the method or property will ensure that the listed field and property members have non- values when returning with the specified return value condition. Gets the return value condition. Gets field or property member names. Initializes the attribute with the specified return value condition and a field or property member. The return value condition. If the method returns this value, the associated parameter will not be . The field or property member that is promised to be not-. Initializes the attribute with the specified return value condition and list of field and property members. The return value condition. If the method returns this value, the associated parameter will not be . The list of field and property members that are promised to be not-null. Specifies that this constructor sets all required members for the current type, and callers do not need to set any required members themselves. Specifies the syntax used in a string. Initializes the with the identifier of the syntax used. The syntax identifier. Initializes the with the identifier of the syntax used. The syntax identifier. Optional arguments associated with the specific syntax employed. Gets the identifier of the syntax used. Optional arguments associated with the specific syntax employed. The syntax identifier for strings containing composite formats for string formatting. The syntax identifier for strings containing date format specifiers. The syntax identifier for strings containing date and time format specifiers. The syntax identifier for strings containing format specifiers. The syntax identifier for strings containing format specifiers. The syntax identifier for strings containing JavaScript Object Notation (JSON). The syntax identifier for strings containing numeric format specifiers. The syntax identifier for strings containing regular expressions. The syntax identifier for strings containing time format specifiers. The syntax identifier for strings containing format specifiers. The syntax identifier for strings containing URIs. The syntax identifier for strings containing XML. States a dependency that one member has on another. This can be used to inform tooling of a dependency that is otherwise not evident purely from metadata and IL, for example a member relied on via reflection. Initializes a new instance of the class with the specified signature of a member on the same type as the consumer. The signature of the member depended on. Initializes a new instance of the class with the specified signature of a member on a . The signature of the member depended on. The containing . Initializes a new instance of the class with the specified signature of a member on a type in an assembly. The signature of the member depended on. The full name of the type containing the specified member. The assembly name of the type containing the specified member. Initializes a new instance of the class with the specified types of members on a . The types of members depended on. The containing the specified members. Initializes a new instance of the class with the specified types of members on a type in an assembly. The types of members depended on. The full name of the type containing the specified members. The assembly name of the type containing the specified members. Gets the signature of the member depended on. Either must be a valid string or must not equal , but not both. Gets the which specifies the type of members depended on. Either must be a valid string or must not equal , but not both. Gets the containing the specified member. If neither nor are specified, the type of the consumer is assumed. Gets the full name of the type containing the specified member. If neither nor are specified, the type of the consumer is assumed. Gets the assembly name of the specified type. is only valid when is specified. Gets or sets the condition in which the dependency is applicable, e.g. "DEBUG". Specifies the types of members that are dynamically accessed. This enumeration has a attribute that allows a bitwise combination of its member values. Specifies no members. Specifies the default, parameterless public constructor. Specifies all public constructors. Specifies all non-public constructors. Specifies all public methods. Specifies all non-public methods. Specifies all public fields. Specifies all non-public fields. Specifies all public nested types. Specifies all non-public nested types. Specifies all public properties. Specifies all non-public properties. Specifies all public events. Specifies all non-public events. Specifies all interfaces implemented by the type. Specifies all members. Indicates that certain members on a specified are accessed dynamically, for example through . This allows tools to understand which members are being accessed during the execution of a program. This attribute is valid on members whose type is or . When this attribute is applied to a location of type , the assumption is that the string represents a fully qualified type name. If the attribute is applied to a method it's treated as a special case and it implies the attribute should be applied to the "this" parameter of the method. As such the attribute should only be used on instance methods of types assignable to System.Type (or string, but no methods will use it there). Initializes a new instance of the class with the specified member types. The types of members dynamically accessed. Gets the which specifies the type of members dynamically accessed. Indicates that the specified method requires the ability to generate new code at runtime, for example through . This allows tools to understand which methods are unsafe to call when compiling ahead of time. Initializes a new instance of the class with the specified message. A message that contains information about the usage of dynamic code. Gets a message that contains information about the usage of dynamic code. Gets or sets an optional URL that contains more information about the method, why it requires dynamic code, and what options a consumer has to deal with it. Indicates that the specified method requires dynamic access to code that is not referenced statically, for example through . This allows tools to understand which methods are unsafe to call when removing unreferenced code from an application. Initializes a new instance of the class with the specified message. A message that contains information about the usage of unreferenced code. Gets a message that contains information about the usage of unreferenced code. Gets or sets an optional URL that contains more information about the method, why it requires unreferenced code, and what options a consumer has to deal with it. Suppresses reporting of a specific rule violation, allowing multiple suppressions on a single code artifact. is different than in that it doesn't have a . So it is always preserved in the compiled assembly. Initializes a new instance of the class, specifying the category of the tool and the identifier for an analysis rule. The category for the attribute. The identifier of the analysis rule the attribute applies to. Gets the category identifying the classification of the attribute. The property describes the tool or tool analysis category for which a message suppression attribute applies. Gets the identifier of the analysis tool rule to be suppressed. Concatenated together, the and properties form a unique check identifier. Gets or sets the scope of the code that is relevant for the attribute. The Scope property is an optional argument that specifies the metadata scope for which the attribute is relevant. Gets or sets a fully qualified path that represents the target of the attribute. The property is an optional argument identifying the analysis target of the attribute. An example value is "System.IO.Stream.ctor():System.Void". Because it is fully qualified, it can be long, particularly for targets such as parameters. The analysis tool user interface should be capable of automatically formatting the parameter. Gets or sets an optional argument expanding on exclusion criteria. The property is an optional argument that specifies additional exclusion where the literal metadata target is not sufficiently precise. For example, the cannot be applied within a method, and it may be desirable to suppress a violation against a statement in the method that will give a rule violation, but not against all statements in the method. Gets or sets the justification for suppressing the code analysis message. Used to indicate a byref escapes and is not scoped. There are several cases where the C# compiler treats a as implicitly - where the compiler does not allow the to escape the method. For example: for instance methods. parameters that refer to types. parameters. This attribute is used in those instances where the should be allowed to escape. Applying this attribute, in any form, has impact on consumers of the applicable API. It is necessary for API authors to understand the lifetime implications of applying this attribute and how it may impact their users. Types and Methods attributed with StackTraceHidden will be omitted from the stack trace text shown in StackTrace.ToString() and Exception.StackTrace Exception thrown when the program executes an instruction that was thought to be unreachable. Initializes a new instance of the class with the default error message. Initializes a new instance of the class with a specified error message. The error message that explains the reason for the exception. Initializes a new instance of the class with a specified error message and a reference to the inner exception that is the cause of this exception. The error message that explains the reason for the exception. The exception that is the cause of the current exception. Static and thread safe wrapper around NullabilityInfoContext. Send a GET request to the specified Uri and return the response body as a stream in an asynchronous operation. This operation will not block. The returned object will complete after the response headers are read. This method does not read nor buffer the response body. The Uri the request is sent to. The cancellation token to cancel the operation. The task object representing the asynchronous operation. Send a GET request to the specified Uri and return the response body as a stream in an asynchronous operation. This operation will not block. The returned object will complete after the response headers are read. This method does not read nor buffer the response body. The Uri the request is sent to. The cancellation token to cancel the operation. The task object representing the asynchronous operation. Send a GET request to the specified Uri and return the response body as a byte array in an asynchronous operation. This operation will not block. The returned Task{Byte[]} object will complete after the response headers are read. This method does not read nor buffer the response body. The Uri the request is sent to. The cancellation token to cancel the operation. The task object representing the asynchronous operation. Send a GET request to the specified Uri and return the response body as a byte array in an asynchronous operation. This operation will not block. The returned Task{byte[]} object will complete after the response headers are read. This method does not read nor buffer the response body. The Uri the request is sent to. The cancellation token to cancel the operation. The task object representing the asynchronous operation. Send a GET request to the specified Uri and return the response body as a string in an asynchronous operation. This operation will not block. The returned object will complete after the response headers are read. This method does not read nor buffer the response body. The Uri the request is sent to. The cancellation token to cancel the operation. The task object representing the asynchronous operation. Send a GET request to the specified Uri and return the response body as a string in an asynchronous operation. This operation will not block. The returned object will complete after the response headers are read. This method does not read nor buffer the response body. The Uri the request is sent to. The cancellation token to cancel the operation. The task object representing the asynchronous operation. Serializes the HTTP content and returns a stream that represents the content. Note that this method will internally buffer the content unless CreateContentReadStreamAsync() has been implemented to do otherwise. The token to monitor for cancellation requests. The default value is . The task object representing the asynchronous operation. Serializes the HTTP content to a byte array as an asynchronous operation. Note that this method will internally buffer the content unless CreateContentReadStreamAsync() has been implemented to do otherwise. The token to monitor for cancellation requests. The default value is . The task object representing the asynchronous operation. Serializes the HTTP content to a string as an asynchronous operation. Note that this method will internally buffer the content unless CreateContentReadStreamAsync() has been implemented to do otherwise. The token to monitor for cancellation requests. The default value is . The task object representing the asynchronous operation. Split the elements of a sequence into chunks of size at most . Every chunk except the last will be of size . The last chunk will contain the remaining elements and may be of a smaller size. An whose elements to chunk. Maximum size of each chunk. The type of the elements of source. An that contains the elements the input sequence split into chunks of size . is null. is below 1. Returns the maximum value in a generic sequence according to a specified key selector function. The type of the elements of . The type of key to compare elements by. A sequence of values to determine the maximum value of. A function to extract the key for each element. The value with the maximum key in the sequence. is . No key extracted from implements the or interface. If is a reference type and the source sequence is empty or contains only values that are , this method returns . Returns the maximum value in a generic sequence according to a specified key selector function. The type of the elements of . The type of key to compare elements by. A sequence of values to determine the maximum value of. A function to extract the key for each element. The to compare keys. The value with the maximum key in the sequence. is . No key extracted from implements the or interface. If is a reference type and the source sequence is empty or contains only values that are , this method returns . Returns the minimum value in a generic sequence according to a specified key selector function. The type of the elements of . The type of key to compare elements by. A sequence of values to determine the minby value of. A function to extract the key for each element. The value with the minimum key in the sequence. is . No key extracted from implements the or interface. If is a reference type and the source sequence is empty or contains only values that are , this method returns . Returns the minimum value in a generic sequence according to a specified key selector function. The type of the elements of . The type of key to compare elements by. A sequence of values to determine the minimum value of. A function to extract the key for each element. The to compare keys. The value with the minimum key in the sequence. is . No key extracted from implements the or interface. If is a reference type and the source sequence is empty or contains only values that are , this method returns . Indicates whether a specified value is found in a read-only span. Values are compared using IEquatable{T}.Equals(T). The value to search for. true if found, false otherwise. Indicates whether a specified value is found in a only span. Values are compared using IEquatable{T}.Equals(T). The value to search for. true if found, false otherwise. Gets the nanosecond component of the time represented by the current object. Gets the nanosecond component of the time represented by the current object. Gets the nanosecond component of the time represented by the current object. Gets the microsecond component of the time represented by the current object. Gets the microsecond component of the time represented by the current object. Gets the microsecond component of the time represented by the current object. Returns a new object that adds a specified number of microseconds to the value of this instance.. Returns a new object that adds a specified number of microseconds to the value of this instance.. Copies the contents of this string into the destination span. The span into which to copy this string's contents Copies the contents of this string into the destination span. The span into which to copy this string's contents true if the data was copied; false if the destination was too short to fit the contents of the string. Reads all characters from the current position to the end of the stream asynchronously and returns them as one string. The token to monitor for cancellation requests. A task that represents the asynchronous read operation. The value of the TResult parameter contains a string with the characters from the current position to the end of the stream. The number of characters is larger than . The stream reader has been disposed. The reader is currently in use by a previous read operation. Reads a line of characters asynchronously and returns the data as a string. The token to monitor for cancellation requests. A value task that represents the asynchronous read operation. The value of the TResult parameter contains the next line from the text reader, or is if all of the characters have been read. The number of characters in the next line is larger than . The text reader has been disposed. The reader is currently in use by a previous read operation. Tries to format the value of the current instance into the provided span of characters. Tries to format the value of the current instance into the provided span of characters. Tries to format the value of the current instance into the provided span of characters. Tries to format the value of the current instance into the provided span of characters. Tries to format the value of the current instance into the provided span of characters. Tries to format the value of the current instance into the provided span of characters. Tries to format the value of the current instance into the provided span of characters. Tries to format the value of the current instance into the provided span of characters. Tries to format the value of the current instance into the provided span of characters. Tries to format the value of the current instance into the provided span of characters. Tries to format the value of the current instance into the provided span of characters. Tries to format the value of the current instance into the provided span of characters. Tries to format the value of the current instance into the provided span of characters. Tries to format the value of the current instance into the provided span of characters. Gets a value that indicates whether the current Type represents a type parameter in the definition of a generic method. Searches for the MemberInfo on the current Type that matches the specified MemberInfo. The MemberInfo to find on the current Type. The MemberInfo to find on the current Type. An object representing the member on the current Type that matches the specified member. Autofilter can sort and filter (hide) values in a non-empty area of a sheet. Each table can have autofilter and each worksheet can have at most one range with an autofilter. First row of the area contains headers, remaining rows contain sorted and filtered data. Sorting of rows is done method, using the passed parameters. The sort properties ( and ) are updated from properties passed to the method. Sorting can be done only on values of one column. Autofilter can filter rows through method. The filter evaluates conditions of the autofilter and leaves visible only rows that satisfy the conditions. Rows that don't satisfy filter conditions are marked as hidden. Filter conditions can be specified for each column (accessible through methods), e.g. sheet.AutoFilter.Column(1).Top(10, XLTopBottomType.Percent) creates a filter that displays only rows with values in top 10% percentile. Get rows of that were hidden because they didn't satisfy filter conditions during last filtering. Visibility is automatically updated on filter change. Is autofilter enabled? When autofilter is enabled, it shows the arrow buttons and might contain some filter that hide some rows. Disabled autofilter doesn't show arrow buttons and all rows are visible. Range of the autofilter. It consists of a header in first row, followed by data rows. It doesn't include totals row for tables. What column was used during last . Contains undefined value for not yet autofilter. Are values in the autofilter range sorted? I.e. the values were either already loaded sorted or has been called at least once. If true, and contain valid values. What sorting order was used during last . Contains undefined value for not yet autofilter. Get rows of that are visible because they satisfied filter conditions during last filtering. Visibility is not updated on filter change. Disable autofilter, remove all filters and unhide all rows of the . Get filter configuration for a column. Column letter that determines number in the range, from A as the first column of a . Filter configuration for the column. Invalid column. Get filter configuration for a column. Column number in the range, from 1 as the first column of a . Filter configuration for the column. Apply autofilter filters to the range and show every row that satisfies the conditions and hide the ones that don't satisfy conditions. Filter is generally automatically applied on a filter change. This method could be called after a cell value change or row deletion. Sort rows of the range using data of one column. This method sets , and properties. Column number in the range, from 1 to width of the . Should rows be sorted in ascending or descending order? Should values on the column be matched case sensitive. true - rows with blank value in the column will always at the end, regardless of sorting order. false - blank will be treated as empty string and sorted accordingly. Type of a filter that is used to determine number of visible top/bottom values. Filter should display requested number of items. Number of displayed items is determined as a percentage data rows of auto filter. AutoFilter filter configuration for one column in an autofilter area. Filters determine visibility of rows in the autofilter area. Value in the row must satisfy all filters in all columns in order for row to be visible, otherwise it is . Column can have only one type of filter, so it's not possible to combine several different filter types on one column. Methods for adding filters clear other types or remove previously set filters when needed. Some types of filters can have multiple conditions (e.g. can have many values while can be only one). Whenever filter configuration changes, the filters are immediately reapplied. Remove all filters from the column. Should the autofilter be immediately reapplied? Switch to the filter if filter column has a different type (for current type ) and add to a set of allowed values. Excel displays regular filter as a list of possible values in a column with checkbox next to it and user can check which one should be displayed. From technical perspective, the passed is converted to a localized string (using current locale) and the column values satisfy the filter condition, when the formatted string of a cell matches any filter string. Examples of less intuitive behavior: filter value is 2.5 in locale cs-CZ that uses "," as a decimal separator. The passed is number 2.5, converted immediately to a string 2,5. The string is used for comparison with values of cells in the column: Number 2.5 formatted with two decimal places as 2,50 will not match. Number 2.5 with default formatting will be matched, because its string is 2,5 in cs-CZ locale (but not in others, e.g. en-US locale). Text 2,5 will be matched. This behavior of course highly depends on locale and working with same file on two different locales might lead to different results. Value of the filter. The type is XLCellValue, but that's for convenience sake. The value is converted to a string and filter works with string. Should the autofilter be immediately reapplied? Fluent API allowing to add additional filter value. Enable autofilter (if needed), switch to the filter if filter column has a different type (for current type ) and add a filter that is satisfied when cell value is a and the tested date has same components from component up to the component with same value as the . The condition basically defines a date range (based on the ) and all dates in the range satisfy the filter. If condition is a day, all date-times in the day satisfy the filter. If condition is a month, all date-times in the month satisfy the filter. Example: // Filter will be satisfied if the cell value is a XLDataType.DateTime and the month, // and year are same as the passed date. The day component in the DateTime // is ignored AddDateGroupFilter(new DateTime(2023, 7, 15), XLDateTimeGrouping.Month) There can be multiple date group filters and they are filter types, i.e. they don't delete filters from . The cell value is satisfied, if it matches any of the text values from or any date group filter. Date which components are compared with date values of the column. Starting component of the grouping. Tested date must match all date components of the from this one to the . Should the autofilter be immediately reapplied? Fluent API allowing to add additional date time group value. If is out of range 1..500. If is out of range 1..500. Current filter type used by the filter columns. Configuration of a filter. It contains how many items/percent (depends on ) should filter accept. Returns undefined value, if is not . Configuration of a filter. It contains the content interpretation of a property, i.e. does it mean how many percents or how many items? Returns undefined value, if is not . Configuration of a filter. It determines if filter should accept items from top or bottom. Returns undefined value, if is not . Configuration of a filter. It determines the type of dynamic filter. Returns undefined value, if is not . Configuration of a filter. It contains the dynamic value used by the filter, e.g. average. The interpretation depends on . Returns undefined value, if is not . A fluent API interface for adding another values to a filter. It is chained by method or . Add another value to a subset of allowed values for a filter. See for more details. Value of the filter. The type is XLCellValue, but that's for convenience sake. The value is converted to a string and filter works with string. Should the autofilter be immediately reapplied? Fluent API allowing to add additional filter value. Add another grouping to a set of allowed groupings. See for more details. Fluent API allowing to add additional date group filter. Key is column number. A single filter condition for auto filter. Value for that is compared using . Value for filter. Basically average for dynamic filters. Value is refreshed during filter reapply. A filter value used by top/bottom filter to compare with cell value. Base interface for an abstract repository. Clear the repository; Put the into the repository under the specified if there is no such key present. Key to identify the value. Value to put into the repository if key does not exist. Value stored in the repository under the specified . If key already existed returned value may differ from the input one. Check if the specified key is presented in the repository. Key to look for. Value from the repository stored under specified key or null if key does not exist or the entry under this key has already bee GCed. True if entry exists and alive, false otherwise. Put the entity into the repository under the specified key if no other entity with the same key is presented. Key to identify the entity. Entity to store. Entity that is stored in the repository under the specified key (it can be either the or another entity that has been added to the repository before.) Enumerate items in repository removing "dead" entries. Base repository for elements. A discriminated union representing any value that can be passed around in the formula evaluation. A value of a blank cell or missing argument. Conversion methods mostly treat blank like 0 or an empty string. Is the value a scalar (blank, logical, number, text or error). Try to get a reference that is a one area from the value. The found area. Original error, if the value is error, #VALUE! if type is not a reference or #REF! if more than one area in the reference. True if area could be determined, false otherwise. Return array from a single area reference or array. If value is scalar, return false. Try to get a value more in line with an array formula semantic. The output is always either single value or an array. Single cell references are turned into a scalar, multi-area references are turned into and single-area references are turned into arrays. Note the difference in nomenclature: single/multi value vs scalar/collection type. Implicit intersection for arguments of functions that don't accept range as a parameter (Excel 2016). Unchanged value for anything other than reference. Reference is changed into a single cell/#VALUE! Create a new reference that has one area that contains both operands or #VALUE! if not possible. Create a new reference by combining areas of both arguments. Areas of the new reference can overlap = some overlapping cells might be counted multiple times (SUM((A1;A1)) = 2 if A1 is 1). Compare two scalar values using Excel semantic. Rules for comparison are following: Logical is always greater than any text (thus transitively greater than any number) Text is always greater than any number, even if empty string Logical are compared by value Numbers are compared by value Text is compared by through case insensitive comparison for workbook culture. If any argument is error, return error (general rule for all operators). If all args are errors, pick leftmost error (technically it is left to implementation, but excel sems to be using left one) Left hand operand of the comparison. Right hand operand of the comparison. Culture to use for comparison. Return -1 (negative) if left less than right Return 1 (positive) if left greater than left Return 0 if both operands are considered equal. Get 2d size of the value. For scalars, it's 1x1, for multi-area references, it's also 1x1,because it is converted to #VALUE! error. Return the array value. A base class for an 2D array. Every array is at least 1x1. Width of the array, at least 1. Height of the array, at least 1. Get a value at specified coordinate. Uses 0-based notation. Uses 0-based notation. An iterator over all elements of an array, from top to bottom, from left to right. Return a new array that was created by applying a function to each element of the array. Return a new array that was created by applying a function to each element of the left and right array. Arrays can have different size and missing values are replaced by #N/A. Broadcast array for calculation of array formulas. An array of scalar values. Array for array literal from a parser. It uses a 1D array of values as a storage. Create a new instance of a . Number of rows of an array/ Number of columns of an array. Row by row data of the array. Has the expected size of an array. A special case of an array that is actually only numbers. An array that retrieves its value directly from the worksheet without allocating extra memory. A resize array from another array. Extra items without value have #N/A. An array where all elements have same value. An array that is a rectangular slice of the original array. Create a sliced array from the original array. Original array. The row offset indicating the starting row of the slice in the original array. The number of rows in the sliced array. The column offset indicating the starting column of the slice in the original array. The number of columns in the sliced array. Base class for all AST nodes. All AST nodes must be immutable. Method to accept a visitor (=call a method of visitor with correct type of the node). A base class for all AST nodes that can be evaluated to produce a value. AST node that contains a blank, logical, number, text or an error value. AST node that contains a constant array. Array is at least 1x1. Unary expression, e.g. +123 Binary expression, e.g. 1+2 A function call, e.g. SIN(0.5). Name of the function. AST nodes for arguments of the function. An placeholder node for AST nodes that are not yet supported in ClosedXML. AST node for an reference to an external file in a formula. If the file is references indirectly, numeric identifier of a file. If a file is referenced directly, a path to the file on the disc/UNC/web link, . AST node for prefix of a reference in a formula. Prefix is a specification where to look for a reference. Prefix specifies a Sheet - used for references in the local workbook. Prefix specifies a FirstSheet and a LastSheet - 3D reference, references uses all sheets between first and last. Prefix specifies a File, no sheet is specified - used for named ranges in external file. Prefix specifies a File and a Sheet - references looks for its address in the sheet of the file. If prefix references data from another file, can be empty. Name of the sheet, without ! or escaped quotes. Can be null in some cases e.g. reference to a named range in an another file). If the prefix is for 3D reference, name of first sheet. Empty otherwise. If the prefix is for 3D reference, name of the last sheet. Empty otherwise. AST node for a reference of an area in some sheet. An optional prefix for reference item. An address of a reference that corresponds to . Always without sheet (that is in the prefix). An area from a parser. Is the reference in A1 style? If false, then it is R1C1. A name node in the formula. Name can refers to a generic formula, in most cases a reference, but it can be any kind of calculation (e.g. A1+7). An optional prefix for reference item. Can be empty if no prefix available. Table of the reference. It can be empty, if formula using the reference is within the table itself (e.g. total formulas). Area of the table that is considered for the range of cell of reference. First column of column range. If the reference refers to the whole table, the value is null. Last column of column range. If structured reference refers only to one column, it is same as . If the reference refers to the whole table, the value is null. Worksheet of the cell the formula is calculating. Worksheet of the cell the formula is calculating. Address of the calculated formula. A culture used for comparisons and conversions (e.g. text to number). Excel 2016 and earlier doesn't support dynamic array formulas (it used an array formulas instead). As a consequence, all arguments for scalar functions where passed through implicit intersection before calling the function. Should functions be calculated per item of multi-values argument in the scalar parameters. Sheet that is being recalculated. If set, formula can read dirty values from other sheets, but not from this sheetId. What date system should be used in calculation. Either 1900 or 1904. An upper limit (exclusive) of used calendar system. A helper method to check is user cancelled the calculation in function loops. This method goes over slices and returns a value for each non-blank cell. Because it is using slice iterators, it scales with number of cells, not a size of area in reference (i.e. it works fine even if reference is A1:XFD1048576). It also works for 3D references. Return all points in the that satisfy the . This method should be used mostly for range arguments. If a value is scalar, return a single value enumerable. A default visitor that copies a formula. Context for , it is used to collect all objects a formula depends on during calculation. An area of a formula, in most cases just one cell, for array formulas area of cells. The result. Visitor adds all areas/names formula depends on to this. Add areas to a list of areas the formula depends on. Disregards duplicate entries. Add name to a list of names the formula depends on. Disregards duplicate entries. Visit each node and determine all ranges that might affect the formula. It uses concrete values (e.g. actual range for structured references) and should be refreshed when structured reference or name is changed in a workbook. The areas found by the visitor shouldn't change when data on a worksheet changes, so the output is a superset of areas, if necessary. Precedents visitor is not completely accurate, in case of uncertainty, it uses a larger area. At worst the end result is unnecessary recalculation. For simple cases, it works fine and freaks like A1:IF(Other!B5,B7,Different!G3) will be marked as dirty more often than strictly necessary. Each node visitor evaluates, if the output is a reference or a value/array. If the result is an array, it propagates to upper nodes, where can be things like range operator. A dependency tree structure to hold all formulas of the workbook and reference objects they depend on. The key feature of dependency tree is to propagate dirty flag across formulas. When a data in a cell changes, all formulas that depend on it should be marked as dirty, but it is hard to find which cells are affected - that is what dependency tree does. Dependency tree must be updated, when structure of a workbook is updated: Sheet is added, renamed or deleted. Name is added or deleted. Table is resized, renamed, added or deleted. Any such action changes what cells formula depends on and the formula dependencies must be updated. The source of the truth, a storage of formula dependencies. The dependency tree is constructed from this collection. Visitor to extract precedents of formulas. A dependency tree for each sheet (key is sheet name). Add a formula to the dependency tree. Area of a formula, for normal cells 1x1, for array can be larger. The cell formula. Workbook that is used to find precedents (names ect.). Added cell formula dependencies. Formula already is in the tree. Remove formula from the dependency tree. Formula to remove. Mark all formulas that depend (directly or transitively) on the area as dirty. An area that is referred by formulas in different cells, i.e. it contains precedent cells for a formula. If anything in the area potentially changes, all dependents might also change. An area in a sheet that is used by formulas, converted to RBush envelope. All RBush double coordinates are whole numbers. The area in a sheet on which some formulas depend on. SIN(A4) depends on A4:A4 area.. List of formulas that depend on the range, always at least one. A dependent on a precedent area. If the precedent area changes, the dependent might also now be invalid. Area that is invalidated, when precedent area is marked as dirty. Generally, it is an area of formula (1x1 for normal formulas), larger for array formulas. Cell formula by itself doesn't contain it's address to make it easier add/delete rows/cols. The formula that is affected by changes in precedent area. A dependency tree for a single worksheet. The precedent areas are not duplicated, though two areas might overlap. All precedent areas in the sheet for all formulas in the workbook. Not sure extra memory (at least 32 bytes per formula) is worth less CPU: O(1) vs O(log N).... Remove a dependency of on a from the sheet dependency tree. A precedent area in the sheet. Formula depending on the . Exception that happens when formula in a cell depends on other cells, but the supporting formulas are still dirty. Evaluation of the formula needs an information that wasn't available. That can happen if the formula is evaluated from methods like . Causes vary, e.g. implicit intersection needs an address of the formula cell. Various methods in ClosedXML are missing different information, e.g. has worksheet, but no cell address (=ranges will work, other things won't). Caches expressions based on their string representation. This saves parsing time. Uses weak references to avoid accumulating unused expressions. The exception that is thrown when the strings to be parsed to an expression is invalid. Initializes a new instance of the ExpressionParseException class with a specified error message. The message that describes the error. A non-state representation of a formula that can be used by many cells. Text of the formula. A list of objects a cell formula depends on. If one of them changes, the formula value might no longer be accurate and needs to be recalculated. List of areas the formula depends on. It is likely a superset of accurate result for unusual formulas, but if a value in an areas changes, the dependent formula should be marked as dirty. A collection of names in the formula. If a name changes (added, deleted), the formula dependencies should be refreshed, because new name might refer to different references (e.g. a name previously referred to A5 and is redefined to B7 or just value 7 => formula no longer depends on A5). Parse a formula into an abstract syntax tree. Factory to create abstract syntax tree for a formula in A1 notation. A prefix for so-called future functions. Excel can add functions, but to avoid name collisions, it prefixes names of function with this prefix. The prefix is omitted from GUI. If you write CONCAT(A1,B1) in Excel 2021 (not present in Excel 2013), it is saved to the worksheet file as _xlfn.CONCAT(A1,B1), but the Excel GUI will show only CONCAT(A1,B1), without the _xlfn. Parse a fraction for text-to-number type coercion. Function definition class (keeps function name, parameter counts, and delegate). Which parameters of the function are marked. The values are indexes of the function parameters, starting from 0. Used to determine which arguments allow ranges and which don't. Evaluate the function with array formula semantic. Function flags that indicate what does function do. It is used by CalcEngine for calculation chain and formula execution. Function that takes an input and returns an output. It is designed for a single value arguments. If scalar function is used for array formula or dynamic array formula, the function is called for each element separately. Non-scalar function. At least one of arguments of the function accepts a range. It means that implicit intersection works differently. Function has side effects, e.g. it changes something. HYPERLINK Function returns array. Functions without this flag return a scalar value. CalcEngine treats such functions differently for array formulas. Function is not deterministic. RAND(), DATE() The function is a future function (i.e. functions not present in Excel 2007). Future functions are displayed to the user with a name (e.g SEC), but are actually stored in the workbook with a prefix _xlfn (e.g. _xlfn.SEC). The prefix is there for backwards compatibility, to not clash with user defined functions and other such reasons. See [MS-XLSX] 2.3.3 for complete list. Which parameters of a function allow ranges. That is important for implicit intersection. None of parameters allow ranges. All parameters allow ranges. All parameters except marked ones allow ranges. Only marked parameters allow ranges. Add a function to the registry. Name of function in formulas. Minimum number of parameters. Maximum number of parameters. A delegate of a function that will be called when function is supposed to be evaluated. Flags that indicate some additional info about function. Which parameters allow ranges to be argument. Useful for array formulas. Index of parameter that is marked, start from 0 An extension methods Aggregate all values in the arguments of a function into a single value. If any value is error, return the error. A lot of functions take all argument values and aggregate the values to a different value. These aggregation functions apply aggregation on each argument and if the argument is a collection (array/reference), the aggregation function is also applied to each element of the array/reference (e.g. SUM({1, 2}, 3) applies sum on each element of an array {1,2} and thus result is 1+2+3). Type of the value that is being aggregated. Arguments of a function. Method goes over all elements of the arguments. Calculation context.> Initial value of the accumulator. It is used as an input into the first call of . What should be the result of aggregation, if there are no elements. Common choices are or the . The aggregation function. First parameter is the accumulator, second parameter is the value of current element taken from . Make sure the method is static lambda to avoid useless allocations. A function that converts a scalar value of an element into the or an error if it can't be converted. Make sure the method is static lambda to avoid useless allocations. Some functions skip elements in a array/reference that would be accepted as an argument, e.g. SUM("1", {2,"4"}) is 3 - it converts string "3" to a number 3 in for root arguments, but omits element "4" in the array. This is a function that determines which elements to include and which to skip. If null, all elements of array are included and all values are treated same. Make sure the method is static lambda to avoid useless allocations. A representation of selection criteria used in IFs functions {SUM,AVERAGE,COUNT}{IF,IFS} and database functions (D{AVERAGE,COUNT,COUNTA,...}). Can a blank value match the criteria? There has to be a None comparison, because criteria empty string ("") matches blank and empty string. That is not same as "=" or actual blank value. Thus it can't be reduced to equal with some operand and has to have a special case. Serial date of 9999-12-31. Date is generally considered invalid, if above that or below 0. Calculate week day. No checks. The default form is form 3 (week starts at Sun, range 1..7). A date type unconstrained by DateTime limitations (1900-01-00 or 1900-02-29). Has some similar methods as DateTime, but without limit checks. A date type unconstrained by DateTime limitations (1900-01-00 or 1900-02-29). Has some similar methods as DateTime, but without limit checks. Return day of year, starting from 1 to 365/366. Counts 1900 as 366 leap year. Find index of the greatest element smaller or equal to the . Value to look for. Data in ascending order. A comparator for comparing two values. Index of found element. If the contains a sequence of values, it can be index of any of them. Find a row with a value of same type as between values and - 1. We know that both and contain value of the same type, so we always get a valid row. Find row index of an element with same type as the lookup value. Go from to the by a step of . If there isn't any such row, return -1. A collection of adapter functions from a more a generic formula function to more specific ones. An adapter for {SUM,AVERAGE}IFS functions. An adapter for COUNTIFS function. Adapt a function that accepts areas as arguments (e.g. SUMPRODUCT). The key benefit is that all ReferenceArray allocation is done once for a function. The method shouldn't be used for functions that accept 3D references (e.g. SUMSQ). It is still necessary to check all errors in the , adapt method doesn't do that on its own (potential performance problem). The signature uses an array instead of IReadOnlyList interface for performance reasons (can't JIT access props through interface). A tally function for *A functions (e.g. AverageA, MinA, MaxA). The behavior is buggy in Excel, because they doesn't count logical values in array, but do count them in reference ¯\_(ツ)_/¯. Scalar values are converted to number, conversion might lead to errors. Array values includes numbers, ignore logical and text. Reference values include logical, number and text is considered a zero. Errors are propagated. Scalar values are converted to number, conversion might lead to errors. Array values includes numbers, text is considered a zero and logical values are ignored. Reference values include logical, number and text is considered a zero. Errors are propagated. Scalar values are converted to number, conversion might lead to errors. Array values includes numbers, text is considered a zero and logical values are ignored. Reference values include logical, number and text is considered a zero. Errors are considered zero and are not propagated. Tally algorithm for SUBTOTAL functions 1..11. Tally algorithm for SUBTOTAL functions 101..111. Tally for {SUM,COUNT,AVERAGE}IF/S and database function. The created tally must contain all selection areas and associated criteria. The main function is then called with values that will be tallied, based on the areas+criteria in the tally object. A collection of areas that are tested and if all satisfy the criteria, corresponding values in the tally areas are tallied. A method to convert a value in the tally area to a number. If scalar value shouldn't be tallied, return null. Add criteria to the tally that limit which values should be tallied. Tally numbers. Ignore blank from scalar values. Basically used for PRODUCT function, so it doesn't end up with 0. Tally algorithm for SUBTOTAL functions 1..11. Tally algorithm for SUBTOTAL functions 101..111. Tally numbers. Any error (including conversion), logical, text is ignored and not tallied. The method tries to convert scalar arguments to numbers, but ignores non-numbers in reference/array. Any error found is propagated to the result. Maximum integer number that can be precisely represented in a double. Calculated as Math.Pow(2, 53) - 1, but use literal to make it constant (=usable in pattern matching). Key: roman form. Value: A collection of subtract symbols and subtract value. Collection is sorted by subtract value in descending order. Calculate SUM((x_i - mean_x)^2) and number of samples. This method uses two-pass algorithm. There are several one-pass algorithms, but they are not numerically stable. In this case, accuracy takes precedence (plus VAR/STDEV are not a very frequently used function). Excel might have used those one-pass formulas in the past (see Statistical flaws in Excel), but doesn't seem to be using them anymore. Characters 0x80 to 0xFF of win-1252 encoding. Core doesn't include win-1252 encoding, so keep conversion table in this string. Reference is a collection of cells in the workbook. It's used in formula evaluation. Every reference has at least one cell. Ctor that reuses parameter to keep allocations low - don't modify the collection after it is passed to ctor. List of areas of the range (at least one). All areas are valid and normalized. Some areas have worksheet and some don't. Get total number of cells coverted by all areas (double counts overlapping areas). An iterator over all nonblank cells of the range. Some cells can be iterated over multiple times (e.g. a union of two ranges with overlapping cells). Do an implicit intersection of an address. An address of the intersection or error if intersection failed. A representation of a value as a discriminated union. A bare bone copy of OneOf that can be more optimized: readonly struct to get rid of defensive copies struct can be smaller through offsets (based on NoBox) allows to pass additional arguments to Match function to skip a need to instantiate a new lambda instance on each call and allow easier inlining. A blank value of a scalar. It can behave as a 0 or empty string, depending on context. A1+5 is a number 5, blank behaves as 0, A1 & "text" is a "text", blank behaves as empty string. Convert value to text. Error is not convertible. Convert value to number. Error is not convertible. Parse text to a scalar value. Generally used in formulas or autofilter. Text to parse. Culture used for parsing numbers or dates. Parsed scalar value. Try to pick a number (interpret blank as number 0). Does this value have same type as the other one? Get the logical value, if it is either blank (false), logical or number (0 = false, otherwise true)a text TRUE or FALSE (case insensitive). Used for coercion in functions. A comparer of a scalar logic. Each comparer with it's logic can be accessed through a static property. Compare scalar values according to logic of "Sort" data in Excel, though texts are compared case insensitive. Order is Type Number, from low to high Type Text, from low to high (non-culture specific, ordinal compare) Type Logical, FALSE, then TRUE. Type Error, all error values are treated as equal (at least they don't change order). Type Blank, all values are treated as equal. A parser of timespan format used by excel during coercion from text to number. parsing methods don't allow for several features required by excel (e.g. seconds/minutes over 60, hours over 24). Parser can parse following formats from ECMA-376, Part 1, §18.8.30. due to standard text-to-number coercion: Format 20 - h:mm. Format 21 - h:mm:ss. Format 47 - mm:ss.0 (format is incorrectly described as mmss.0 in the standard, but fixed in an implementation errata). Timespan is never interpreted through format 45 (mm:ss), instead preferring the format 20 (h:mm). Timespan is never interpreted through format 46 ([h]:mm:ss], such values are covered by format 21 (h:mm:ss). Note that the decimal fraction differs format 20 and 47, thus mere addition of decimal place means significantly different values. Parser also copies features of Excel, like whitespaces around a decimal place (10:20 . 5 is allowed). 20:30 is detected as format 20 and the first number is interpreted as hours, thus the serial time is 0.854167. 20:30.0 is detected as format 47 and the first number is interpreted as minutes, thus the serial time is 0.014236111. A collection of all references in the book (not others) found in a formula. Created by . Is there a #REF! anywhere in the formula? Areas without a sheet found in the formula. Areas with a sheet found in the formula. Factory to get all references (cells, tables, names) in local workbook. Add necessary prefixes to a user-supplied future functions without a prefix (e.g. acot(A5)/2 to _xlfn.ACOT(A5)/2). All functions must have chars in the .-_ range (trie range). Indicates the node represents a full prefix. Leaves are always ends and middle nodes sometimes (e.g. AB and ABC). Something transitions to this tree. Index is a character minus . The possible range of characters is from to . A visitor for that maps one name of a function to another. Case insensitive dictionary of function names. A factory to rename named reference object (sheets, tables ect.). A mapping of sheets, from old name (key) to a new name (value). The null value indicates sheet has been deleted. A wildcard is at most 255 chars long text. It can contain * which indicates any number characters (including zero) and ? which indicates any single character. If you need to find * or ? in a text, prefix them with an escape character ~. Search for the wildcard anywhere in the text. Text used to search for a pattern. zero-based index of a first character in a text that matches to a pattern or -1, if match wasn't found. Match the pattern against input. Pattern matches whole input. Does the start of an input match the pattern? CalcEngine parses strings and returns Expression objects that can be evaluated. This class has three extensibility points: Use the RegisterFunction method to define custom functions. Parses a string into an . String to parse. An formula that can be evaluated. Add an array formula to the calc engine to manage dirty tracking and evaluation. Add a formula to the calc engine to manage dirty tracking and evaluation. Remove formula from dependency tree (=precedents won't mark it as dirty) and remove from the chain. Note that even if formula is used by many cells (e.g. array formula), it is fully removed from dependency tree, but each cells referencing the formula must be removed individually from calc chain. Recalculate a workbook or a sheet. Evaluates a normal formula. Expression to evaluate. Workbook where is formula being evaluated. Worksheet where is formula being evaluated. Address of formula. Should the data necessary for this formula (not deeper ones) be calculated recursively? Used only for non-cell calculations. If set, calculation will allow dirty reads from other sheets than the passed one. The value of the expression. If you are going to evaluate the same expression several times, it is more efficient to parse it only once using the method and then using the Expression.Evaluate method to evaluate the parsed expression. Convert any kind of formula value to value returned as a content of a cell. bool - represents a logical value. double - represents a number and also date/time as serial date-time. string - represents a text value. - represents a formula calculation error. A calculation chain of formulas. Contains all formulas in the workbook. Calculation chain is an ordering of all cells that have value calculated by a formula (note that one formula can determine value of multiple cells, e.g. array). Formulas are calculated in specified order and if currently processed formula needs data from a cell whose value is dirty (i.e. it is determined by a not-yet-calculated formula), the current formula is stopped and the required formula is placed before the current one and starts to be processed. Once it is done, the original formula is starts to be processed again. It might have encounter another not-yet-calculated formula or it will finish and the calculation chain moves to the next one. Chain can be traversed through , , and , but only one traversal can go on at the same time due to shared info about cycle detection. Key to the that is the head of the chain. Null, when chain is empty. Key to the that is the tail of the chain. Null, when chain is empty. Doubly circular linked list containing all points with value calculated by a formula. The chain is "looped", so it doesn't have to deal with nulls for . There is always exactly one loop, no cycles. The formulas might cause cycles due to dependencies, but that is manifested by constantly switching the links in a loop. 1 based position of , if there is a traversal in progress (0 otherwise). The address of a current of the chain. Is there a cycle in the chain? Detected when a link has appeared as a current more than once and the current hasn't moved in the meantime. Create a new chain filled with all formulas from the workbook. Add a new link at the beginning of a chain. Add all cells from the area to the end of the chain. If chain already contains a cell from the area. Append formula at the end of the chain. Initialize empty chain with a single link chain. Insert a link into the between and . Don't update head or tail. Add a link for after the link for . The anchor point after which will be the new point added. Point to add to the chain. The last position of the point in the chain. Remove point from the chain. Link to remove. Last position of the removed link. Point is not a part of the chain. Clear whole chain. Enumerate all links in the chain. Mark current link as complete and move ahead to the next link. true if the enumerator moved ahead, false if there are no more links and chain has looped completely. Move the before the current point as the new current to be calculated. The point of a chain to moved to the current. Should always be in the chain after the current. What was the 1-based position of the link in the chain the last time the link has been current. Only used when link is pushed to the back, otherwise it's 0. The last position of a link is only updated when Link is moved from current to the back - that means link will be moved to current again at some point in the future and if chain hasn't processed even one link in the meantime, there is a cycle. Link is marked as done and current moves past it. The last position should be cleared as not to confuse next traversal. Chain traversal is reset - links in front of current may still have set their last position, because other links have been moved to the current as a supporting links. Used for cycle detection. Comparer of ranges that ignores whether row/column is fixes or not. A blank value. Used as a value of blank cells or as an optional argument for function calls. Represents the sole instance of the class. A formula error. Keep order of errors in same order as value returned by ERROR.TYPE, because it is used for comparison in some case (e.g. AutoFilter). Values are off by 1, so default produces a valid error. #NULL! - Intended to indicate when two areas are required to intersect, but do not. The space is an intersection operator. SUM(B1 C1) tries to intersect B1:B1 area and C1:C1 area, but since there are no intersecting cells, the result is #NULL. #DIV/0! - Intended to indicate when any number (including zero) or any error code is divided by zero. #VALUE! - Intended to indicate when an incompatible type argument is passed to a function, or an incompatible type operand is used with an operator. Passing a non-number text to a function that requires a number, trying to get an area from non-contiguous reference. Creating an area from different sheets Sheet1!A1:Sheet2!A2 #REF! - a formula refers to a cell that's not valid. When unable to find a sheet or a cell. #NAME? - Intended to indicate when what looks like a name is used, but no such name has been defined. Only for named ranges, not sheets. TestRange*10 when the named range doesn't exist will result in an error. #NUM! - Intended to indicate when an argument to a function has a compatible type, but has a value that is outside the domain over which that function is defined. This is known as a domain error. ASIN(10) - the ASIN accepts only argument -1..1 (an output of SIN), so the resulting value is #NUM!. #N/A - Intended to indicate when a designated value is not available. The value is used for extra cells of an array formula that is applied on an array of a smaller size that the array formula. Set all cells in a to the array formula. This method doesn't check that formula doesn't damage other array formulas. Mark all formulas in a range as dirty. An interface for components reacting on changes in a worksheet. A handler called after the area was put into the sheet and cells shifted down. Sheet where change happened. Area that has been inserted. The original cells were shifted down. A handler called after the area was put into the sheet and cells shifted right. Sheet where change happened. Area that has been inserted. The original cells were shifted right. A handler called after the area was deleted from the sheet and cells shifted left. Sheet where change happened. Range that has been deleted and cells to the right were shifted left. A handler called after the area was deleted from the sheet and cells shifted up. Sheet where change happened. Range that has been deleted and cells below were shifted up. An interface for methods of without specified type of an element. Is at least one cell in the slice used? Get maximum used column in the slice or 0, if no column is used. Get maximum used row in the slice or 0, if no row is used. A set of columns that have at least one used cell. Order of columns is non-deterministic. A set of rows that have at least one used cell. Order of rows is non-deterministic. Clear all values in the range and mark them as unused. Clear all values in the and shift all values right of the deleted area to the deleted place. Clear all values in the and shift all values below the deleted area to the deleted place. Get all used points in a slice. Range to iterate over. false = left to right, top to bottom. true = right to left, bottom to top. Shift all values at the and all cells below it down by of the . The insert area is cleared. Shift all values at the and all cells right of it to the right by of the . The insert area is cleared. Does slice contains a non-default value at specified point? Swap content of two points. Listener for components that need to be notified about structural changes of a workbook (adding/removing sheet, renaming). See for similar listener about structural changes of a sheet. Method is called when sheet has already been renamed. Each component is responsible only for changing data in itself, not other components. The goal is to separate concerns so each component is not too dependent on others and can achieve the goal in efficient manner. Old sheet name. New sheet name, different from old one. A value that is in the cell. The value is a blank (either blank cells or the omitted optional argument of a function, e.g. IF(TRUE,,). Keep as the first, so the default values are blank. The value is a logical value. The value is a double-precision floating points number, excluding , or . A text or a rich text. Can't be null and can be at most 32767 characters long. The value is one of . The value is a , represented as a serial date time number. Serial date time 60 is a 1900-02-29, nonexistent day kept for compatibility, but unrepresentable by DateTime. Don't use. The value is a , represented in a serial date time (24 hours is 1, 36 hours is 1.5 ect.). Is this cell the active cell of the worksheet? Setting false deactivates cell only when the cell is currently active. Gets this cell's address, relative to the worksheet. The cell's address. Get the value of a cell without evaluation of a formula. If the cell contains a formula, it returns the last calculated value or a blank value. If the cell doesn't contain a formula, it returns same value as . May hold invalid value when flag is True. Can be useful to decrease a number of formula evaluations. Returns the current region. The current region is a range bounded by any combination of blank rows and blank columns The current region. Gets the type of this cell's data. The type of the cell's data. Gets or sets the cell's formula with A1 references. Setter trims the formula and if formula starts with an =, it is removed. If the formula contains unprefixed future function (e.g. CONCAT), it will be correctly prefixed (e.g. _xlfn.CONCAT). The formula with A1 references. Gets or sets the cell's formula with R1C1 references. Setter trims the formula and if formula starts with an =, it is removed. If the formula contains unprefixed future function (e.g. CONCAT), it will be correctly prefixed (e.g. _xlfn.CONCAT). The formula with R1C1 references. An indication that value of this cell is calculated by a array formula that calculates values for cells in the referenced address. Null if not part of such formula. Flag indicating that previously calculated cell value may be not valid anymore and has to be re-evaluated. Only cells with formula may return true, value cells always return false. Gets or sets a value indicating whether this cell's text should be shared or not. If false the cell's text will not be shared and stored as an inline value. Gets or sets the cell's style. Gets or sets the cell's value. Getter will return value of a cell or value of formula. Getter will evaluate a formula, if the cell , before returning up-to-date value. Setter will clear a formula, if the cell contains a formula. If the value is a text that starts with a single quote, setter will prefix the value with a single quote through in Excel too and the value of cell is set to to non-quoted text. Should the cell show phonetic (i.e. furigana) above the rich text of the cell? It shows phonetic runs in the rich text, it is not autogenerated. Default is false. Creates a named range out of this cell. If the named range exists, it will add this range to that named range. The default scope for the named range is Workbook. Name of the range. Creates a named range out of this cell. If the named range exists, it will add this range to that named range. Name of the range. The scope for the named range. Creates a named range out of this cell. If the named range exists, it will add this range to that named range. Name of the range. The scope for the named range. The comments for the named range. Returns this cell as an IXLRange. Clears the contents of this cell. Specify what you want to clear. Copy range content to an area of same size starting at the cell. Original content of cells is overwritten. Range whose content to copy. This cell. Creates a new comment for the cell, replacing the existing one. Creates a new data validation rule for the cell, replacing the existing one. Creates a new hyperlink replacing the existing one. Replaces a value of the cell with a newly created rich text object. Deletes the current cell and shifts the surrounding cells according to the shiftDeleteCells parameter. How to shift the surrounding cells. Returns the comment for the cell or create a new instance if there is no comment on the cell. Returns a data validation rule assigned to the cell, if any, or creates a new instance of data validation rule if no rule exists. Gets the cell's value as a Boolean. Shortcut for Value.GetBoolean() If the value of the cell is not a logical. Gets the cell's value as a Double. Shortcut for Value.GetNumber() If the value of the cell is not a number. Gets the cell's value as a String. Shortcut for Value.GetText(). Returned value is never null. If the value of the cell is not a text. Gets the cell's value as a XLError. Shortcut for Value.GetError() If the value of the cell is not an error. Gets the cell's value as a DateTime. Shortcut for Value.GetDateTime() If the value of the cell is not a DateTime. Gets the cell's value as a TimeSpan. Shortcut for Value.GetTimeSpan() If the value of the cell is not a TimeSpan. Try to get cell's value converted to the T type. Supported types: Boolean - uses a logic of Number (s/byte, u/short, u/int, u/long, float, double, or decimal) - uses a logic of and succeeds, if the value fits into the target type. String - sets the result to a text representation of a cell value (using current culture). DateTime - uses a logic of TimeSpan - uses a logic of XLError - if the value is of type , it will return the value. Enum - tries to parse a value to a member by comparing the text of a cell value and a member name. If the is a nullable value type and the value of cell is blank or empty string, return null value. If the cell value can't be determined because formula function is not implemented, the method always returns false. The requested type into which will the value be converted. Value to store the value. true if the value was converted and the result is in the , false otherwise. Conversion logic is identical with . The requested type into which will the value be converted. If the value can't be converted to the type of T Return cell's value represented as a string. Doesn't use cell's formatting or style. Gets the cell's value formatted depending on the cell's data type and style. Culture used to format the string. If null (default value), use current culture. Returns a hyperlink for the cell, if any, or creates a new instance is there is no hyperlink. Returns the value of the cell if it formatted as a rich text. Inserts the IEnumerable data elements and returns the range it occupies. The IEnumerable data. Inserts the IEnumerable data elements and returns the range it occupies. The IEnumerable data. if set to true the data will be transposed before inserting. Inserts the data of a data table. The data table. The range occupied by the inserted data Inserts the IEnumerable data elements as a table and returns it. The new table will receive a generic name: Table# The table data. Inserts the IEnumerable data elements as a table and returns it. The new table will receive a generic name: Table# The table data. if set to true it will create an Excel table. if set to false the table will be created in memory. Creates an Excel table from the given IEnumerable data elements. The table data. Name of the table. Inserts the IEnumerable data elements as a table and returns it. The table data. Name of the table. if set to true it will create an Excel table. if set to false the table will be created in memory. Inserts the DataTable data elements as a table and returns it. The new table will receive a generic name: Table# The table data. Inserts the DataTable data elements as a table and returns it. The new table will receive a generic name: Table# The table data. if set to true it will create an Excel table. if set to false the table will be created in memory. Creates an Excel table from the given DataTable data elements. The table data. Name of the table. Inserts the DataTable data elements as a table and returns it. The table data. Name of the table. if set to true it will create an Excel table. if set to false the table will be created in memory. Invalidate so the formula will be re-evaluated next time is accessed. If cell does not contain formula nothing happens. Set hyperlink of a cell. When user clicks on a cell with hyperlink, the Excel opens the target or moves cursor to the target cells in a worksheet. The text of hyperlink is a cell value, the hyperlink target and tooltip are defined by the parameter. If the cell uses worksheet style, the method also sets hyperlink font color from theme and the underline property. The new cell hyperlink. Use null to remove the hyperlink. This cell. Returns a string that represents the current state of the cell according to the format. A: address, F: formula, NF: number format, BG: background color, FG: foreground color, V: formatted value Sets the cells' value. Setter will clear a formula, if the cell contains a formula. If the value is a text that starts with a single quote, setter will prefix the value with a single quote through in Excel too and the value of cell is set to to non-quoted text. Clears the contents of these cells. Specify what you want to clear. Delete the comments of these cells. Delete the sparklines of these cells. Sets the cells' formula with A1 references. The formula with A1 references. Sets the cells' formula with R1C1 references. The formula with R1C1 references. A class that holds all texts in a workbook. Each text can be either a simple string or a . Table of Id to text. Some ids are empty (entry.RefCount = 0) and are tracked in . List of indexes in that are unused. text -> id Number of texts the table holds reference to. Get a string for specified id. Doesn't matter if it is a plain text or a rich text. In both cases, return text. The principle is that every entry is a text, but only some are rich text. This tries to get a rich text, if it is one. If it is just plain text, return null. Get id for a text and increase a number of references to the text by one. Id of a text in the SST. Decrease reference count of a text and free if necessary. Get a map that takes the actual string id and returns an continuous sequence (i.e. no gaps). If an id if free (no ref count), the id is mapped to -1. A struct to hold a text. It also needs a flag for inline/shared, because they have to be different in the table. If there was no inline/shared flag, there would be no way to easily determine whether a text should be written to sst or it should be inlined. Either a string, XLImmutableRichText or null if == 0. Must be as flag for inline string, so the default value is false => ShareString is true by default How many objects (cells, pivot cache entries...) reference the text. Slice is a sparse array that stores a part of cell information (e.g. only values, only styles ...). Slice has same size as a worksheet. If some cells are pushed out of the permitted range, they are gone. This is a ref return, so if the underlaying value changes, the returned value also changes. To avoid, just don't use ref and structs will be copied. The type of data stored in the slice. The content of the slice. Note that LUT uses index that starts from 0, so rows and columns must be adjusted to retrieved the value. Key is column number, value is number of cells in the column that are used. Get the slice value at the specified point of the sheet. Get the slice value at the specified point of the sheet. Get enumerator over used values of the range. Enumerator that returns used values from a specified range. The movement is columns first, then rows. Memory efficient look up table. The table is 2-level structure, where elements of the the top level are potentially nullable references to buckets of up-to 32 items in bottom level. Both level can increase size through doubling, through only the top one can be indefinite size. The default value lut ref returns for elements not defined in the lut. A sparse array of values in the lut. The top level always allocated at least one element. Get maximal node that is used. Return -1 if LUT is unused. Does LUT contains at least one used element? Get a value at specified index. Index, starting at 0. Reference to an element at index, if the element is used, otherwise . Does the index set a mask of used index (=was value set and not cleared)? Set/clar an element at index to a specified value. The used flag will be if the value is default or not. A bucket of bottom layer of LUT. Each bucket has up-to 32 elements. A bitmap array that indicates which nodes have a set/no-default values values (1 = value has been set and there is an element in the , 0 = value hasn't been set and might exist or not). If the element at some index is not is not set and lut is asked for a value, it should return . The length of the bitmap array is same as the , for each bottom level bucket, the element of index 0 in the bucket is represented by lowest bit, element 31 is represented by highest bit. This is useful to make a distinction between a node that is empty and a node that had it's value se to . Enumerator of LUT used values from low index to high. Create a new enumerator from subset of elements. Lookup table to traverse. First desired index, included. Last desired index, included. Index of current element in the LUT. Only valid, if enumerator is valid. Enumerator of LUT used values from high index to low index. A slice of a single worksheet for values of a cell. Prepare for worksheet removal, dereference all tests in a slice. A cell value in a very compact representation. The value is interpreted depending on a type. Type of a cell . A flag indicating if a string should be stored in the shared table or inline. Overriden , because we can't store the value in the cell. A formula in the cell. Null, if cell doesn't contain formula. Set value of a cell and its format (if necessary) from the passed value. It doesn't clear formulas or checks merged cells or tables. Perform an evaluation of cell formula. If cell does not contain formula nothing happens, if cell does not need recalculation ( is False) nothing happens either, unless flag is specified. Otherwise recalculation is performed, result value is preserved in and returned. Flag indicating whether a recalculation must be performed even is cell does not need it. Null if cell does not contain a formula. Calculated value otherwise. Set only value, don't clear formula, don't set format. Sets the value even for merged cells. Flag indicating that previously calculated cell value may be not valid anymore and has to be re-evaluated. The sparkline assigned to the cell Get the data validation rule containing current cell. The data validation rule applying to the current cell or null if there is no such rule. Ensure the cell has style set directly on the cell, not inherited from column/row/worksheet styles. Get glyph bounding boxes for each grapheme in the text. Box size is determined according to the font of a grapheme. New lines are represented as default (all dimensions zero) box. A line without any text (i.e. contains only new line) should be represented by a box with zero advance width, but with a line height of corresponding font. Engine used to determine box size. DPI used to determine size of glyphs. List where items are added. A representation of a cell formula, not the formula itself (i.e. the tree). This is only a placeholder, so the data table formula looks like array formula for saving code. First argument is replaced by value from current row, second is replaced by value from current column. Is this formula dirty, i.e. is it potentially out of date due to changes to precedent cells? Formula in A1 notation. Doesn't start with = sign. Range for array and data table formulas, otherwise default value. Doesn't contain sheet, so it doesn't have to deal with sheet renames and moving formula around. True, if 1D data table formula is the row (the displayed formula in Excel is missing the second argument {=TABLE(A1;)}). False the 1D data table is a column. (the displayed formula in Excel is missing the first argument {=TABLE(;A1)}) This property is meaningless, if called for non-data-table formula. If data table is in row (i.e. the value returns true) that means it calculates values in a row, it takes formula from a cell from a column one less than its range and replaces the input cell with value at the intersection of current cell column and the top row of the range. When data table is a column, it works pretty much same, except axis are reversed. Just because data table is 1D doesn't mean its range has to be. It can be rectangular even for 1D data table. It just means that data table is applied separately to each row/column (depending on whether the data table is row or column). True, if data table is 2D and uses both inputs. Input1 is replaced by value from current row, input2 is replaced by a value from current column. This property is meaningless, if called for non-data-table formula. Returns a cell that data table formula uses as a variable to replace with values for the actual table. Used for 1D data table formula as a single input (row or column) and as row for 2D data table. Must be present, even if input marked as deleted. This property is meaningless, if called for non-data-table formula. Returns a cell that 2D data table formula uses as a variable to replace with values for the actual table. The value is taken from the top of range of the current column. Must be present for 2D, even if input marked as deleted. This property is meaningless, if called for non-data-table formula. Returns true, if data table formula has its input1 deleted. This property is meaningless, if called for non-data-table formula. Returns true, if data table formula has its input1 deleted. This property is meaningless, if called for non-data-table formula. Get stored formula in R1C1 notation. Returned formula doesn't contain equal sign. A factory method to create a normal A1 formula. Doesn't affect recalculation version. Formula in A1 form. Shouldn't start with =. A factory method to create an array formula. Doesn't affect recalculation version. Isn't wrapped in {} and doesn't start with =. A range of cells that are calculated through the array formula. A flag for always calculate array. A factory method to create a cell formula for 1D data table formula. Doesn't affect recalculation version. Range of the data table formula. Even 1D table can have rectangular range. Address of the input cell that will be replaced in the data table. If input deleted, ignored and value can be anything. Was the original address deleted? Is data table in row (true) or columns (false)? A factory method to create a 2D data table formula. Doesn't affect recalculation version. Range of the formula. Address of the input cell that will be replaced in the data table. If input deleted, ignored and value can be anything. Was the original address deleted? Address of the input cell that will be replaced in the data table. If input deleted, ignored and value can be anything. Was the original address deleted? An enum to efficiently store various flags for formulas (bool takes up 1-4 bytes due to alignment). Note that each type of formula uses different flags. For Array formula. Not fully clear from documentation, but seems to be some kind of dirty flag. Current excel just writes ca="1" to each cell of array formula for cases described in the DOC. For data table formula. Flag whether the data table is 2D and has two inputs. For data table formula. If the set, the data table is in row, not column. It uses input1 in both case, but the position is interpreted differently. For data table formula. When the input 1 cell has been deleted (not content, but the row or a column where cell was), this flag is set. For data table formula. When the input 2 cell has been deleted (not content, but the row or a column where cell was), this flag is set. Get a lazy initialized AST for the formula. Engine to parse the formula into AST, if necessary. Get all used cells in the worksheet. Get all used cells in the worksheet that satisfy the predicate. Get all used cells in the range that satisfy the predicate. Get all used cells in the range that satisfy the predicate. Get cell or null, if cell is not used. Remap rows of a range. A sorted map of rows. The values must be resorted row numbers from . Sheet that should have its rows rearranged. Remap columns of a range. A sorted map of columns. The values must be resorted columns numbers from . Sheet that should have its columns rearranged. Gets used points in the range. Enumerator that combines several other slice enumerators and enumerates in any of them. Gets or sets the width of this column in number of characters (NoC). NoC are a non-linear units displayed as a column width in Excel, next to pixels. NoC combined with default font of the workbook can express width of the column in pixels and other units. Deletes this column and shifts the columns at the right of this one accordingly. Don't use in a loop due to poor performance. Use instead. Gets this column's number Gets this column's letter Inserts X number of columns at the right of this one. All columns at the right will be shifted accordingly. The number of columns to insert. Inserts X number of columns at the left of this one. This column and all at the right will be shifted accordingly. The number of columns to insert. Gets the cell in the specified row. The cell's row. Returns the specified group of cells, separated by commas. e.g. Cells("1"), Cells("1:5"), Cells("1,3:5") The column cells to return. Returns the specified group of cells. The first row in the group of cells to return. The last row in the group of cells to return. Adjusts the width of the column based on its contents. Adjusts the width of the column based on its contents, starting from the startRow. The row to start calculating the column width. Adjusts the width of the column based on its contents, starting from the startRow and ending at endRow. The row to start calculating the column width. The row to end calculating the column width. Adjust width of the column according to the content of the cells. Number of a first row whose content is considered. Number of a last row whose content is considered. Minimum width of adjusted column, in NoC. Maximum width of adjusted column, in NoC. Hides this column. Unhides this column. Gets a value indicating whether this column is hidden or not. true if this column is hidden; otherwise, false. Gets or sets the outline level of this column. The outline level of this column. Adds this column to the next outline level (Increments the outline level for this column by 1). Adds this column to the next outline level (Increments the outline level for this column by 1). If set to true the column will be shown collapsed. Sets outline level for this column. The outline level. Sets outline level for this column. The outline level. If set to true the column will be shown collapsed. Adds this column to the previous outline level (decrements the outline level for this column by 1). Adds this column to the previous outline level (decrements the outline level for this column by 1). If set to true it will remove this column from all outline levels. Show this column as collapsed. Expands this column (if it's collapsed). Adds a vertical page break after this column. Clears the contents of this column. Specify what you want to clear. Sets the width of all columns. The width of all columns. Deletes all columns and shifts the columns at the right of them accordingly. Adjusts the width of all columns based on its contents. Adjusts the width of all columns based on its contents, starting from the startRow. The row to start calculating the column width. Adjusts the width of all columns based on its contents, starting from the startRow and ending at endRow. The row to start calculating the column width. The row to end calculating the column width. Hides all columns. Unhides all columns. Increments the outline level of all columns by 1. Increments the outline level of all columns by 1. If set to true the columns will be shown collapsed. Sets outline level for all columns. The outline level. Sets outline level for all columns. The outline level. If set to true the columns will be shown collapsed. Decrements the outline level of all columns by 1. Decrements the outline level of all columns by 1. If set to true it will remove the columns from all outline levels. Show all columns as collapsed. Expands all columns (if they're collapsed). Returns the collection of cells. Returns the collection of cells that have a value. Returns the collection of cells that have a value. if set to true will return all cells with a value or a style different than the default. Adds a vertical page break after these columns. Clears the contents of these columns. Specify what you want to clear. The direct constructor should only be used in . Calculate column width in pixels according to the content of cells. First row number whose content is used for determination. Last row number whose content is used for determination. Engine to determine size of glyphs. DPI of the worksheet. Adds a vertical page break after this column. Create a new instance of . If worksheet is specified it means that the created instance represents all columns on a worksheet so changing its width will affect all columns. Default style to use when initializing child entries. A predefined enumerator of to support lazy initialization. Adds a vertical page break after this column. Gets or sets this comment's author's name Sets the name of the comment's author Author's name Adds a bolded line with the author's name The first of the . Priority of formatting rule. Lower values have higher priority than higher values. Minimum value is 1. It is basically used for ordering of CF during saving. A container for conditional formatting of a . It contains a collection of . Doesn't contain pivot table formats, they are in pivot table , The method consolidate the same conditional formats, which are located in adjacent ranges. Reorders the according to original priority. Done during load process Absolute units of physical length. Pixels are relative units to the size of screen. 1 pt = 1/72 inch 1 pc = 12pt. English metric unit. English metric unit. Length in EMU. Return length in specified unit. Reference to a single cell in a workbook. Reference can be absolute, relative or mixed. Reference can be with or without a worksheet. Worksheet of the reference. Value is null for address without a worksheet. Create address without worksheet. For calculation only! Initializes a new struct using a mixed notation. Attention: without worksheet for calculation only! The row number of the cell address. The column letter of the cell address. Initializes a new struct using a mixed notation. The row number of the cell address. The column letter of the cell address. Initializes a new struct using R1C1 notation. Attention: without worksheet for calculation only! The row number of the cell address. The column number of the cell address. Initializes a new struct using R1C1 notation. The row number of the cell address. The column number of the cell address. Gets the row number of this address. Gets the column number of this address. Gets the column letter(s) of this address. A specification of an area (rectangular range) of a sheet. Name of the sheet. Sheet may exist or not (e.g. deleted). Never null. An area in the sheet. Perform an intersection. The area that is being intersected with this one. The intersection (=same sheet and has non-empty intersection) or null if intersection isn't possible. A single point in a workbook. The book point might point to a deleted worksheet, so it might be invalid. Make sure it is checked when determining the properties of the actual data of the point. TODO: SheetId doesn't work nicely with renames, but will in the future. A sheet id of a point. Id of a sheet never changes during workbook lifecycle (), but the sheet may be deleted, making the sheetId and thus book point invalid. A point in the sheet. A name in a worksheet. Unlike , this is basically only a reference. The actual Name of a sheet. If null, the scope is a workbook. The sheet might not exist, e.g. it is only in a formula. The name of a sheet is not escaped. The defined name in the scope. Case insensitive during comparisons. A reference without a sheet. Can represent single cell (A1), area (B$4:$D$10), row span (4:10) and col span (G:H). This is an actual representation of a reference, while the is for an absolute are of a sheet and is only for a cell reference and only for area reference. An offset of a cell in a sheet. The row offset in number of rows from the original point. The column offset in number of columns from the original point An offset of a cell in a sheet. The row offset in number of rows from the original point. The column offset in number of columns from the original point The row offset in number of rows from the original point. The column offset in number of columns from the original point An point (address) in a worksheet, an equivalent of ST_CellRef. Unlike the XLAddress, sheet can never be invalid. 1-based row number in a sheet. 1-based column number in a sheet. Get offset that must be added to so we can get . Parse point per type ST_CellRef from 2.1.1108 Part 4 Section 3.18.8, ST_CellRef (Cell Reference) Input text If the input doesn't match expected grammar. Try to parse sheet point. Doesn't accept any extra whitespace anywhere in the input. Letters must be upper case. Write the sheet point as a reference to the span (e.g. A1). Must be at least 10 chars long Number of chars Create a sheet point from the address. Workbook is ignored. Is the point within the range or below the range? Is the point within the range or to the left of the range? Return a new point that has its row coordinate shifted by . How many rows will new point be shifted. Positive - new point is downwards, negative - new point is upwards relative to the current point. Shifted point. Return a new point that has its column coordinate shifted by . How many columns will new point be shifted. Positive - new point is to the right, negative - new point is to the left. Shifted point. A representation of a ST_Ref, i.e. an area in a sheet (no reference to the sheet). A range that covers whole worksheet. Top-left point of the sheet range. Bottom-right point of the sheet range. The left column number of the range. From 1 to . The right column number of the range. From 1 to . Greater or equal to . The top row number of the range. From 1 to . The bottom row number of the range. From 1 to . Greater or equal to . Parse point per type ST_Ref from 2.1.1119 Part 4 Section 3.18.64, ST_Ref (Cell Range Reference) Can be one cell reference (A1) or two separated by a colon (A1:B2). First reference is always in top left corner Input text If the input doesn't match expected grammar. Try to parse area. Doesn't accept any extra whitespace anywhere in the input. Letters must be upper case. Area can specify one corner (A1) or both corners (A1:B3). Write the sheet range to the span. If range has only one cell, write only the cell. Must be at least 21 chars long. Number of written characters. Return a range that contains all cells below the current range. The range touches the bottom border of the sheet. Get a range below the current one rows. If there isn't enough rows, use as many as possible. The range touches the bottom border of the sheet. Return a range that contains all cells to the right of the range. The range touches the right border of the sheet. Return a range that contains additional number of rows below. Return a range that contains additional number of columns to the right. Create a new range from this one by taking a number of rows from the bottom row up. How many rows to take, must be at least one. Create a new range from this one by taking a number of rows from the top row down. How many rows to take, must be at least one. Create a new range from this one by taking a number of rows from the left column to the right. How many columns to take, must be at least one. Create a new range from this one by taking a number of rows from the bottom row up. How many columns to take, must be at least one. Create a new sheet range that is a result of range operator (:) of this sheet range and The other range. A range that contains both this range and . Does this range intersects with . true if intersects, false otherwise. Do an intersection between this range and other range. Other range. The intersection range if it exists and is non-empty or null, if intersection doesn't exist. Does this range overlaps the ? Does range cover all rows, from top row to bottom row of a sheet. Does range cover all columns, from first to last column of a sheet. Return a new range that has the same size as the current one, New top left coordinate of returned range. New range. Return a new range that has been shifted in vertical direction by . By how much to shift the range, positive - downwards, negative - upwards. Newly created area. Return a new range that has been shifted in horizontal direction by . By how much to shift the range, positive - rightward, negative - leftward. Newly created area. Calculate size and position of the area when another area is inserted into a sheet. Inserted area. The result, might be null as a valid result if area is pushed out. true if results wasn't partially shifted. Calculate size and position of the area when another area is inserted into a sheet. Inserted area. The result, might be null as a valid result if area is pushed out. true if results wasn't partially shifted. Take the area and reposition it as if the was removed from sheet. If cells the left of the area are deleted, the area shifts to the left. If is within the area, the width of the area decreases. If the method returns false, there is a partial cover and it's up to you to decide what to do. The has a value null if the range was completely removed by . Take the area and reposition it as if the was removed from sheet. If cells upward of the area are deleted, the area shifts to the upward. If is within the area, the height of the area decreases. If the method returns false, there is a partial cover and it's up to you to decide what to do. The has a value null if the range was completely removed by . that includes a sheet. It can represent cell ('Sheet one'!A$1), area (Sheet1!A4:$G$5), row span ('Sales Q1'!4:10) and col span (Sales!G:H). Name of a sheet. Unescaped, so it doesn't include quotes. Note that sheet might not exist. Referenced area in the sheet. Can be in A1 or R1C1. that includes a sheet. It can represent cell ('Sheet one'!A$1), area (Sheet1!A4:$G$5), row span ('Sales Q1'!4:10) and col span (Sales!G:H). Name of a sheet. Unescaped, so it doesn't include quotes. Note that sheet might not exist. Referenced area in the sheet. Can be in A1 or R1C1. Name of a sheet. Unescaped, so it doesn't include quotes. Note that sheet might not exist. Referenced area in the sheet. Can be in A1 or R1C1. A collection of ranges the data validation rule applies too. Add a range to the collection of ranges this rule applies to. If the specified range does not belong to the worksheet of the data validation rule it is transferred to the target worksheet. A range to add. Add a collection of ranges to the collection of ranges this rule applies to. Ranges that do not belong to the worksheet of the data validation rule are transferred to the target worksheet. Ranges to add. Detach data validation rule of all ranges it applies to. Remove the specified range from the collection of range this rule applies to. A range to remove. Add data validation rule to the collection. If the specified rule refers to another worksheet than the collection, the copy will be created and its ranges will refer to the worksheet of the collection. Otherwise the original instance will be placed in the collection. A data validation rule to add. The instance that has actually been added in the collection (may be a copy of the specified one). Get all data validation rules applied to ranges that intersect the specified range. Get the data validation rule for the range with the specified address if it exists. A range address. Data validation rule which ranges collection includes the specified address. The specified range should be fully covered with the data validation rule. For example, if the rule is applied to ranges A1:A3,C1:C3 then this method will return True for ranges A1:A3, C1:C2, A2:A3, and False for ranges A1:C3, A1:C1, etc. True is the data validation rule was found, false otherwise. Add a range to the collection of ranges this rule applies to. If the specified range does not belong to the worksheet of the data validation rule it is transferred to the target worksheet. A range to add. Add a collection of ranges to the collection of ranges this rule applies to. Ranges that do not belong to the worksheet of the data validation rule are transferred to the target worksheet. Ranges to add. Detach data validation rule of all ranges it applies to. Remove the specified range from the collection of range this rule applies to. A range to remove. The flag used to avoid unnecessary check for splitting intersected ranges when we already are performing the splitting. Get all data validation rules applied to ranges that intersect the specified range. Get the data validation rule for the range with the specified address if it exists. A range address. Data validation rule which ranges collection includes the specified address. The specified range should be fully covered with the data validation rule. For example, if the rule is applied to ranges A1:A3,C1:C3 then this method will return True for ranges A1:A3, C1:C2, A2:A3, and False for ranges A1:C3, A1:C1, etc. True is the data validation rule was found, false otherwise. Class used for indexing data validation rules. Gets an object with the boundaries of this range. A scope of . It determines where can be defined name resolved. Name is defined at the sheet level and is available only at the sheet it is defined or collection or when referred with sheet specifier (e.g. Sheet5!Name when name is scoped to Sheet5). Name is defined at the workbook and is available everywhere. Gets or sets the comment for this named range. The comment for this named range. Checks if the named range contains invalid references (#REF!). Defined name with a formula SUM(#REF!A1, Sheet7!B4) would return true, because #REF!A1 is an invalid reference. Gets or sets the name of the range. The name of the range. Set value is not a valid name. The name is colliding with a different name that is already defined in the collection. Gets the ranges associated with this named range. Note: A named range can point to multiple ranges. A formula of the named range. In most cases, name is just a range (e.g. Sheet5!$A$4), but it can be a constant, lambda or other values. The name formula can contain a bang reference (e.g. reference without a sheet, but with exclamation mark !$A$5), but can't contain plain local cell references (i.e. references without a sheet like A5). Gets the scope of this named range. Gets or sets the visibility of this named range. true if visible; otherwise, false. Copy sheet-scoped defined name to a different sheet. The references to the original sheet are changed to refer to the : Cell ranges (Org!A1 will be New!A1). Tables - if the target sheet contains a table of same size at same place as the original sheet. Sheet-specified names (Org!Name will be New!Name, but the actual name won't be created). Target sheet where to copy the defined name. Defined name is workbook-scoped Trying to copy defined name to the same sheet. Deletes this named range (not the cells). Gets the specified defined name. Name identifier. Name wasn't found. Adds a new defined name. Name identifier to add. The range address to add. The name or address is invalid. Adds a new defined name. Name identifier to add. The range to add. The name is invalid. Adds a new defined name. Name identifier to add. The ranges to add. The name is invalid. Adds a new defined name. Name identifier to add. The range address to add. The comment for the new named range. The range name or address is invalid. Adds a new defined name. Name identifier to add. The range to add. The comment for the new named range. The range name is invalid. Adds a new defined name. Name identifier to add. The ranges to add. The comment for the new named range. The range name is invalid. Deletes the specified defined name. Deleting defined name doesn't delete referenced cells. Name identifier to delete. Deletes the specified defined name's index. Deleting defined name doesn't delete referenced cells. Index of the defined name to delete. The index is outside of named ranges array. Deletes all defined names of this collection, i.e. a workbook or a sheet. Deleting defined name doesn't delete referenced cells. Returns a subset of defined names that do not have invalid references. Returns a subset of defined names that do have invalid references. Get sheet references found in the formula in A1. Doesn't return tables or name references, only what has col/row coordinates. A collection of a named ranges, either for workbook or for worksheet. Adds the specified range name. Name of the range. The range address. The comment. if set to true validates the name. if set to true range address will be checked for validity. For named ranges in the workbook scope, specify the sheet name in the reference. Returns a subset of named ranges that do not have invalid references. Returns a subset of named ranges that do have invalid references. Type of image. The supported formats are defined by OpenXML's ImagePartType. Default value is "jpeg" Current width of the picture in pixels. Current height of the picture in pixels. Original height of the picture in pixels. Original width of the picture in pixels. Create a copy of the picture on a different worksheet. The worksheet to which the picture will be copied. A created copy of the picture. Deletes this picture. Create a copy of the picture on the same worksheet. A created copy of the picture. Create a copy of the picture on a different worksheet. The worksheet to which the picture will be copied. A created copy of the picture. Create a copy of the picture on the same worksheet. A created copy of the picture. Left margin in inches. Right margin in inches. Top margin in inches. Bottom margin in inches. Set , , , margins at once. A reference to the data in a worksheet is not valid. E.g. sheet with specific name doesn't exist, name doesn't exist. Remove the hyperlink from a worksheet. Doesn't throw if hyperlinks is not attached to a worksheet. If hyperlink range uses a hyperlink theme color, the style is reset to the sheet style font color. The is also set to sheet style underline. Hyperlink to remove. true if hyperlink was part of the worksheet and was removed. false otherwise. Delete a hyperlink defined for a single cell. It doesn't delete hyperlinks that cover the cell. If hyperlink range uses a hyperlink theme color, the style is reset to the sheet style font color. The is also set to sheet style underline. Address of the cell. true if there was such hyperlink and was deleted. false otherwise. Get a hyperlink for a single cell. Address of the cell. Cell doesn't have a hyperlink. Get a hyperlink for a single cell. Address of the cell. Found hyperlink. true if there was a hyperlink for , false otherwise. Add a hyperlink. Doesn't modify style, unlike public API. Remove a hyperlink. Doesn't modify style, unlike public API. Gets top left cell of a hyperlink range. Return null, if the hyperlink isn't in a worksheet. Tooltip displayed when user hovers over the hyperlink range. If not specified, the link target is displayed in the tooltip. A universal interface for different data readers used in InsertData logic. Get a collection of records, each as a collection of values, extracted from a source. Get the number of properties to use as a table with. Actual number of may vary in different records. Get the title of the property with the specified index. Conditional formats for pivot tables, loaded from sheets. Key is sheet name, value is the conditional formats. A dictionary of styles from styles.xml. Used in other places that reference number style by id reference. Constants used across writers. Valid and shorter than normal true. Valid and shorter than normal false. An exception thrown from parser when there is a problem with data in XML. The exception messages are rather generic and not very helpful, but they aren't supposed to be. If this exception is thrown, there is either a problem with producer of a workbook or ClosedXML. Both should do investigation based on a the file causing an error. Create a new exception with info that some element that should be present in a workbook is missing. optional info about what element is missing. A field displayed as ∑Values in a pivot table that contains names of all aggregation function in value fields collection. Also commonly called 'data' field. A writer for table definition part. Populates the differential formats that are currently in the file to the SaveContext Check if two style are equivalent. Style in the OpenXML format. Style in the ClosedXML format. Flag specifying whether or not compare the alignments of two styles. Styles in x:cellStyleXfs section do not include alignment so we don't have to compare it in this case. Styles in x:cellXfs section, on the opposite, do include alignments, and we must compare them. True if two formats are equivalent, false otherwise. Stream detached worksheet DOM to the worksheet part stream. Replaces the content of the part. An array to convert data type for a formula cell. Key is . It saves some performance through direct indexation instead of switch. An array to convert data type for a cell that only contains a value. Key is . It saves some performance through direct indexation instead of switch. Gets or sets the column after which the horizontal split should take place. Gets or sets the row after which the vertical split should take place. Gets or sets the location of the top left visible cell The scroll position's top left cell. Window zoom magnification for current view representing percent values. Horizontal and vertical scale together. Representing percent values ranging from 10 to 400. Zoom magnification to use when in normal view. Horizontal and vertical scale together Representing percent values ranging from 10 to 400. Zoom magnification to use when in page layout view. Horizontal and vertical scale together. Representing percent values ranging from 10 to 400. Zoom magnification to use when in page break preview. Horizontal and vertical scale together. Representing percent values ranging from 10 to 400. Freezes the specified rows and columns. The rows to freeze. The columns to freeze. Freezes the left X columns. The columns to freeze. Freezes the top X rows. The rows to freeze. Gets or sets the workbook's calculation mode. Gets or sets the default column width for the workbook. All new worksheets will use this column width. Gets an object to manipulate this workbook's defined names. Gets or sets the default outline options for the workbook. All new worksheets will use these outline options. Gets or sets the default page options for the workbook. All new worksheets will use these page options. Gets all pivot caches in a workbook. A one cache can be used by multiple tables. Unused caches are not saved. Gets or sets the workbook's properties. Gets or sets the workbook's reference style. Gets or sets the default row height for the workbook. All new worksheets will use this row height. Gets or sets the default style for the workbook. All new worksheets will use this style. Gets an object to manipulate this workbook's theme. Gets an object to manipulate the worksheets. Add a worksheet with a table at Cell(row:1, column:1). The dataTable's name is used for the worksheet name. The name of a table will be generated as Table{number suffix}. Datatable to insert Inserted Worksheet Add a worksheet with a table at Cell(row:1, column:1). The sheetName provided is used for the worksheet name. The name of a table will be generated as Table{number suffix}. dataTable to insert as Excel Table Worksheet and Excel Table name Inserted Worksheet Add a worksheet with a table at Cell(row:1, column:1). dataTable to insert as Excel Table Worksheet name Excel Table name Inserted Worksheet Evaluate a formula expression. Formula expression to evaluate. If the expression contains a function that requires a context (e.g. current cell or worksheet). Try to find a defined name. If specifies a sheet, try to find name in the sheet first and fall back to the workbook if not found in the sheet. Requested name Sheet1!Name will first try to find Name in a sheet Sheet1 (if such sheet exists) and if not found there, tries to find Name in workbook. Requested name Name will be searched only in a workbooks . Name of requested name, either plain name (e.g. Name) or with sheet specified (e.g. Sheet!Name). Found name or null. Force recalculation of all cell formulas. Saves the current workbook. Saves the current workbook and optionally performs validation Saves the current workbook to a file. Saves the current workbook to a file and optionally validates it. Saves the current workbook to a stream. Saves the current workbook to a stream and optionally validates it. Searches the cells' contents for a given piece of text The search text. The compare options. if set to true search formulae instead of cell values. Gets the Excel table of the given name Name of the table to return. One of the enumeration values that specifies how the strings will be compared. The table with given name If no tables with this name could be found in the workbook. Gets the workbook that contains this worksheet Gets or sets the default column width for this worksheet. Gets or sets the default row height for this worksheet. Gets or sets the name (caption) of this worksheet. The sheet rename also renames sheet in formulas and defined names. Gets or sets the position of the sheet. When setting the Position all other sheets' positions are shifted accordingly. Gets an object to manipulate the sheet's print options. Gets an object to manipulate the Outline levels. All hyperlinks in the sheet. Gets the first row of the worksheet. Gets the first non-empty row of the worksheet that contains a cell with a value. Formatted empty cells do not count. Gets the first non-empty row of the worksheet that contains a cell with a value. The options to determine whether a cell is used. Gets the last row of the worksheet. Gets the last non-empty row of the worksheet that contains a cell with a value. Gets the last non-empty row of the worksheet that contains a cell with a value. The options to determine whether a cell is used. Gets the first column of the worksheet. Gets the first non-empty column of the worksheet that contains a cell with a value. Gets the first non-empty column of the worksheet that contains a cell with a value. The options to determine whether a cell is used. Gets the last column of the worksheet. Gets the last non-empty column of the worksheet that contains a cell with a value. Gets the last non-empty column of the worksheet that contains a cell with a value. The options to determine whether a cell is used. Gets a collection of all columns in this worksheet. Gets a collection of the specified columns in this worksheet, separated by commas. e.g. Columns("G:H"), Columns("10:11,13:14"), Columns("P:Q,S:T"), Columns("V") The columns to return. Gets a collection of the specified columns in this worksheet. The first column to return. The last column to return. Gets a collection of the specified columns in this worksheet. The first column to return. The last column to return. Gets a collection of all rows in this worksheet. Gets a collection of the specified rows in this worksheet, separated by commas. e.g. Rows("4:5"), Rows("7:8,10:11"), Rows("13") The rows to return. Gets a collection of the specified rows in this worksheet. The first row to return. The last row to return. Gets the specified row of the worksheet. The worksheet's row. Gets the specified column of the worksheet. The worksheet's column. Gets the specified column of the worksheet. The worksheet's column. Gets the cell at the specified row and column. The cell's row. The cell's column. Gets the cell at the specified address. The cell address in the worksheet. Address is not A1 or workbook-scoped named range. Gets the cell at the specified row and column. The cell's row. The cell's column. Gets the cell at the specified address. The cell address in the worksheet. Returns the specified range. The range boundaries. Returns the specified range. e.g. Range("A1"), Range("A1:C2") The range boundaries. is not a valid address or named range. Returns the specified range. The first cell in the range. The last cell in the range. Returns the specified range. The first cell address in the worksheet. The last cell address in the worksheet. Returns the specified range. The first cell address in the worksheet. The last cell address in the worksheet. Returns a collection of ranges, separated by commas. e.g. Ranges("A1"), Ranges("A1:C2"), Ranges("A1:B2,D1:D4") The ranges to return. Returns the specified range. The first cell's row of the range to return. The first cell's column of the range to return. The last cell's row of the range to return. The last cell's column of the range to return. . Gets the number of rows in this worksheet. Gets the number of columns in this worksheet. Collapses all outlined rows. Collapses all outlined columns. Expands all outlined rows. Expands all outlined columns. Collapses the outlined rows of the specified level. The outline level. Collapses the outlined columns of the specified level. The outline level. Expands the outlined rows of the specified level. The outline level. Expands the outlined columns of the specified level. The outline level. Deletes this worksheet. Gets an object to manage this worksheet's defined names. Gets the specified defined name. Name identifier of defined name, without sheet name. Name wasn't found in sheets defined names. Gets an object to manage how the worksheet is going to displayed by Excel. Gets the Excel table of the given index Index of the table to return Gets the Excel table of the given name Name of the table to return Gets an object to manage this worksheet's Excel tables Copies the Copy a worksheet from this workbook to a different workbook as a new sheet. Workbook into which copy this sheet. Name of new sheet in the where will the data be copied. Sheet will be in the last position. Newly created sheet in the . The active cell of the worksheet. Evaluate an formula and return a result. Formula to evaluate. A cell address that is used to provide context for formula calculation (mostly implicit intersection). If was needed for some part of calculation. Force recalculation of all cell formulas in the sheet while leaving other sheets without change, even if their dirty cells. A class that defines various aspects of a newly created workbook. A graphics engine that will be used for workbooks without explicitly set engine. Should all formulas in a workbook be recalculated during load? Default value is false. Graphic engine used by the workbook. DPI for the workbook. Default is 96. Used in various places, e.g. determining a physical size of an image without a DPI or to determine a size of a text in a cell. Gets the left header/footer item. Gets the middle header/footer item. Gets the right header/footer item. Gets the text of the specified header/footer occurrence. The occurrence. Gets the text of the specified header/footer occurrence. The occurrence. Adds the given predefined text to this header/footer item. The predefined text to add to this header/footer item. Adds the given text to this header/footer item. The text to add to this header/footer item. The occurrence for the text. Adds the given predefined text to this header/footer item. The predefined text to add to this header/footer item. The occurrence for the predefined text. Clears the text/formats of this header/footer item. The occurrence to clear. Gets or sets the Left margin. The Left margin. Gets or sets the Right margin. The Right margin. Gets or sets the Top margin. The Top margin. Gets or sets the Bottom margin. The Bottom margin. Gets or sets the Header margin. The Header margin. Gets or sets the Footer margin. The Footer margin. Gets an object to manage the print areas of the worksheet. Gets the first row that will repeat on the top of the printed pages. Use SetRowsToRepeatAtTop() to set the rows that will be repeated on the top of the printed pages. Gets the last row that will repeat on the top of the printed pages. Use SetRowsToRepeatAtTop() to set the rows that will be repeated on the top of the printed pages. Sets the rows to repeat on the top of the printed pages. The range of rows to repeat on the top of the printed pages. Sets the rows to repeat on the top of the printed pages. The first row to repeat at top. The last row to repeat at top. Gets the first column to repeat on the left of the printed pages. The first column to repeat on the left of the printed pages. Gets the last column to repeat on the left of the printed pages. The last column to repeat on the left of the printed pages. Sets the rows to repeat on the left of the printed pages. The first column to repeat at left. The last column to repeat at left. Sets the rows to repeat on the left of the printed pages. The range of rows to repeat on the left of the printed pages. Gets or sets the page orientation for printing. The page orientation. Gets or sets the number of pages wide (horizontal) the worksheet will be printed on. If you don't specify the PagesTall, Excel will adjust that value based on the contents of the worksheet and the PagesWide number. Setting this value will override the Scale value. Gets or sets the number of pages tall (vertical) the worksheet will be printed on. If you don't specify the PagesWide, Excel will adjust that value based on the contents of the worksheet and the PagesTall number. Setting this value will override the Scale value. Gets or sets the scale at which the worksheet will be printed. The worksheet will be printed on as many pages as necessary to print at the given scale. Setting this value will override the PagesWide and PagesTall values. Gets or sets the horizontal dpi for printing the worksheet. Gets or sets the vertical dpi for printing the worksheet. Gets or sets the page number that will begin the printout. For example, the first page of your printout could be numbered page 5. First page number can be negative, e.g. -2. Gets or sets a value indicating whether the worksheet will be centered on the page horizontally. true if the worksheet will be centered on the page horizontally; otherwise, false. Gets or sets a value indicating whether the worksheet will be centered on the page vertically. true if the worksheet will be centered on the page vertically; otherwise, false. Sets the scale at which the worksheet will be printed. This is equivalent to setting the Scale property. The worksheet will be printed on as many pages as necessary to print at the given scale. Setting this value will override the PagesWide and PagesTall values. The scale at which the worksheet will be printed. Gets or sets the number of pages the worksheet will be printed on. This is equivalent to setting both PagesWide and PagesTall properties. Setting this value will override the Scale value. The pages wide. The pages tall. Gets or sets the size of the paper to print the worksheet. Gets an object to work with the page margins. Gets an object to work with the page headers. Gets an object to work with the page footers. Gets or sets a value indicating whether Excel will automatically adjust the font size to the scale of the worksheet. true if Excel will automatically adjust the font size to the scale of the worksheet; otherwise, false. Gets or sets a value indicating whether the header and footer margins are aligned with the left and right margins of the worksheet. true if the header and footer margins are aligned with the left and right margins of the worksheet; otherwise, false. Gets or sets a value indicating whether the gridlines will be printed. true if the gridlines will be printed; otherwise, false. Gets or sets a value indicating whether to show row numbers and column letters/numbers. true to show row numbers and column letters/numbers; otherwise, false. Gets or sets a value indicating whether the worksheet will be printed in black and white. true if the worksheet will be printed in black and white; otherwise, false. Gets or sets a value indicating whether the worksheet will be printed in draft quality. true if the worksheet will be printed in draft quality; otherwise, false. Gets or sets the page order for printing. Gets or sets how the comments will be printed. Gets a list with the row breaks (for printing). Gets a list with the column breaks (for printing). Adds a horizontal page break after the given row. The row to insert the break. Adds a vertical page break after the given column. The column to insert the break. Gets or sets how error values will be printed. > First page number or null for auto/default page numbering. Removes the print areas from the worksheet. Adds a range to the print areas. The first cell row. The first cell column. The last cell row. The last cell column. Adds a range to the print areas. The range address to add. Adds a range to the print areas. The first cell address. The last cell address. Adds a range to the print areas. The first cell address. The last cell address. Implementation of QuadTree adapted to Excel worksheet specifics. Differences with the classic implementation are that the topmost level is split to 128 square parts (2 columns of 64 blocks, each 8192*8192 cells) and that splitting the quadrant onto 4 smaller quadrants does not depend on the number of items in this quadrant. When the range is added to the QuadTree it is placed on the bottommost level where it fits to a single quadrant. That means, row-wide and column-wide ranges are always placed at the level 0, and the smaller the range is the deeper it goes down the tree. This approach eliminates the need of transferring ranges between levels. Smaller quadrants which the current one is split to. Is NULL until ranges are added to child quadrants. The level of current quadrant. Top most has level 0, child quadrants has levels (Level + 1). Minimum column included in this quadrant. Minimum row included in this quadrant. Maximum column included in this quadrant. Maximum row included in this quadrant. Collection of ranges belonging to this quadrant (does not include ranges from child quadrants). The number of current quadrant by horizontal axis. The number of current quadrant by vertical axis. Add a range to the quadrant or to one of the child quadrants (recursively). True, if range was successfully added, false if it has been added before. Get all ranges from the quadrant and all child quadrants (recursively). Get all ranges from the quadrant and all child quadrants (recursively) that intersect the specified address. Get all ranges from the quadrant and all child quadrants (recursively) that cover the specified address. Remove the range from the quadrant or from child quadrants (recursively). True if the range was removed, false if it does not exist in the QuadTree. Remove all the ranges matching specified criteria from the quadrant and its child quadrants (recursively). Don't use it for searching intersections as it would be much less efficient than . Maximum depth of the QuadTree. Value 10 corresponds to the smallest quadrants having size 16*16 cells. Collection of ranges belonging to the current quadrant (that cannot fit into child quadrants). Add a range to the collection of quadrant's own ranges. True if the range was successfully added, false if it had been added before. Check if the current quadrant fully covers the specified address. Check if the current quadrant covers the specified address. Check if the current quadrant intersects the specified address. Create a collection of child quadrants dividing the current one. A generic version of A type for field index, so there is a better idea what is a semantic content of some variable/props. Not detrimental to performance, JIT will inline struct to int. The index of a 'data' field (). Index of a field in . Can be -2 for 'data' field, otherwise non-negative. Is this index for a 'data' field? A fluent API representation of a field on an row, column or filter axis of a . If the field is a 'data' field, a lot of properties don't make sense and can't be set. In such case, the setter will throw and getter will return default value for the field. Name of the field in a pivot table . If the field is 'data' field, return . Note that field name in pivot cache is generally same as in the source data range, but not always. Field names are unique in the cache and if the source data range contains duplicate column names, the cache will rename them to keep all names unique. of the field in the pivot table. Custom name is a unique across all fields used in the pivot table (e.g. if same field is added to values area multiple times, it must have custom name, e.g. Sum1 of Field, Sum2 of Field). When setting name to a name that is already used by another field. Get subtotals of the field. The content of the collection depends on the type of subtotal: None - the collection is empty. Automatic - the collection contains one element with function . Custom - the collection contains a set of functions (at least one) except the . Are all items of the field collapsed? If only a subset of items is collapsed, getter returns false. Selected values for filter of the pivot table. Empty for non-filter fields. Add a value to selected values of a filter field (). Doesn't do anything, if this field is not a filter fields. Add a values to a selected values of a filter field. Doesn't do anything if this field is not a filter fields. Index of a field in all pivot fields or -2 for data field. A collection of fields on column labels, row labels or report filters of a . Add a field to the axis labels/report filters. Name of the field in . The value can also be for ΣValues field. Display name of added field. Custom name of a filed must be unique in pivot table. Ignored for 'data' field. The added field. Field can't be added (e.g. it is already used or can't be added to specific collection). Remove all fields from the axis. It also removes data of removed fields, like custom names and items. Does this axis contain a field? Name of the field in . Use for data field. true if the axis contains the field, false otherwise. Does this axis contain a field? Checked pivot field. true if the axis contains the field, false otherwise. Get a field in the axis. Name of the field in we are looking for in the axis. Found field. Axis doesn't contain field with specified name. Get field by index in the collection. Index of the field in this collection. Found field. Get index of a field in the collection. Use the index in the method. of the field in the pivot cache. Index of the field or -1 if not found. Get index of a field in the collection. Use the index in the method. Field to find. Uses . Index of the field or -1 if not a member of this collection. Remove a field from axis. Doesn't throw, if field is not present. of a field to remove. Describes an axis of a pivot table. Used to determine which areas should be styled through . [ISO-29500] 18.18.1 ST_Axis(PivotTable Axis). A field that describes calculation of value to display in the area of pivot table. Custom name of the data field (e.g. Sum of Sold). Can be left empty to keep same as source name. Use to get value with fallback. For data fields, the name is duplicated at and here. This property has a preference. Field index to . Unlike axis, this field index can't be -2 for data fields. That field can't be in the data area. An aggregation function that calculates the value to display in the data cells of pivot area. A calculation takes value calculated by aggregation and transforms it into the final value to display to the user. The calculation might need and/or . Index to the base field () when needs a field for its calculation. Index to the base item of when needs an item for its calculation. Formatting to apply to the data field. If disagree, this has precedence. A collection of . Fields displayed in the data area of the pivot table, in the order fields are displayed. A representation of a single row/column axis values in a . Represents 18.10.1.44 i (Row Items) and 18.10.1.96 x (Member Property Index). Each item is an index to field items of corresponding field from . Value 1048832 specifies that no item appears at the position. Type of item. If this item (row/column) contains 'data' field, this contains an index into the that should be used as a value. The value for 'data' field in the is ignored, but Excel fills same number as this index. Representation of item (basically one value of a field). Each value used somewhere in pivot table (e.g. data area, row/column labels and so on) must have an entry here. By itself, it doesn't contain values, it only references shared items of the field in the . [OI29500] 18.10.1.45 item (PivotTable Field Item). If present, must be unique within the containing field items. Flag indicating the item is hidden. Used for . When item field is a page field, the hidden flag mean unselected values in the page filter. Non-hidden values are selected in the filter. Allowed for non-OLAP pivot tables only. Flag indicating that the item has a character value. Allowed for OLAP pivot tables only. Excel uses the sd attribute to indicate whether the item is expanded. Allowed for non-OLAP pivot tables only. Spec for the sd had to be patched.. Allowed for non-OLAP pivot tables only. Item itself is missing from the source data Allowed for non-OLAP pivot tables only. Allowed for OLAP pivot tables only. Index to an item in the sharedItems of the field. The index must be unique in containing field items. When is , it must be set. Never negative. Allowed for OLAP pivot tables only. Attributes sd (show detail) and d (detail) were swapped in spec, fixed by OI29500. A flag that indicates whether details are hidden for this item? d attribute. Allowed for OLAP pivot tables only. Get value of an item from cache or null if not data item. A description of one axis (/) of a . It consists of fields in a specific order and values that make up individual rows/columns of the axis. [ISO-29500] 18.10.1.17 colItems (Column Items), 18.10.1.84 rowItems (Row Items). Fields displayed on the axis, in the order of the fields on the axis. Values of one row/column in an axis. Items are not kept in sync with . A list of fields to displayed on the axis. It determines which fields and in what order should the fields be displayed. Individual row/column parts of the axis. Add field to the axis, as an index. Add a row/column axis values (i.e. values visible on the axis). A fluent API for one field in , either or . Get position of the field on the axis, starting at 0. Page/filter fields of a . It determines filter values and layout. It is accessible through fluent API . Filter fields in correct order. The layout is determined by and . Number of rows/cols occupied by the filter area. Filter area is above the pivot table and it optional (i.e. size 0 indicates no filter). Number of rows/cols occupied by the filter area, including the gap below, if there is at least one filter. Fluent API for filter fields of a . This class shouldn't contain any state, only logic to change state per API. A cache of pivot data - essentially a collection of fields and their values that can be displayed by a . Data for the cache are retrieved from an area (a table or a range). The pivot cache data are cached, i.e. the data in the source are not immediately updated once the data in a worksheet change. Get names of all fields in the source, in left to right order. Every field name is unique. The field names are case insensitive. The field names of the cached source might differ from actual names of the columns in the data cells. Gets the number of unused items in shared items to allow before discarding unused items. Shared items are distinct values of a source field values. Updating them can be expensive and this controls, when should the cache be updated. Application-dependent attribute. Default value is . Will Excel refresh the cache when it opens the workbook. Default value is false. Should the cached values of the pivot source be saved into the workbook file? If source data are not saved, they will have to be refreshed from the source reference which might cause a change in the table values. Default value is true. Refresh data in the pivot source from the source reference data. The data source for the pivot table can't be found. Sets the value to true. Sets the value to true. A collection of pivot caches. Pivot cache can be added from a or a . Add a new pivot cache for the range. If the range area is same as an area of a table, the created cache will reference the table as source of data instead of a range of cells. Range for which to create the pivot cache. The pivot cache for the range. An abstraction of source data for a . Implementations must correctly implement equals. Try to determine actual area of the source reference in the workbook. Source reference might not be valid in the workbook, some might not be supported. Labels displayed in columns (i.e. horizontal axis) of the pivot table. Labels displayed in rows (i.e. vertical axis) of the pivot table. Top left corner cell of a pivot table. If the pivot table contains filters fields, the target cell is top left cell of the first filter field. The cache of data for the pivot table. The pivot table is created from cached data, not up-to-date data in a worksheet. Filter fields layout setting that indicates layout order of filter fields. The layout uses to determine when to break to a new row or column. Default value is . Specifies the number of page fields to display before starting another row or column. Value = 0 means unlimited. If value < 0. Should pivot table display a grand total for each row in the last column of a pivot table (it will enlarge pivot table for extra column). This API has inverse row/column names than the Excel. Excel: On for rows should use this method ShowGrandTotalsColumns. Set the layout of the pivot table. It also changes layout of all pivot fields. Add a pivot table that will use the pivot cache. Name of new pivot table. A cell where will the pivot table be have it's left top corner. Pivot cache to use for the pivot table. Added pivot table. There already is a pivot table with the same name. Add a pivot table from source data of . If workbook already contains a cache for same range as the , the matching pivot cache is used. Name of new pivot table A cell where will the pivot table be have it's left top corner. A range to add/find pivot cache. There already is a pivot table with the same name. Add a pivot table from source data of . If workbook already contains a cache for same range as the , the matching pivot cache is used. Name of new pivot table A cell where will the pivot table be have it's left top corner. A table to add/find pivot cache. There already is a pivot table with the same name. Get pivot table with the specified name (case insensitive). Name of a pivot table to return. No such pivot table found. Interface to change the style of a or its parts. Pivot table style of the field values displayed in the data area of the pivot table. Get the style of the pivot field header. The head usually contains a name of the field. In some layouts, header is not individually displayed (e.g. compact), while in others it is (e.g. tabular). Get the style of the pivot field label values on horizontal or vertical axis. A interface for styling various parts of a pivot table, e.g. the whole table, specific area or just a field. Use and to access it. To what part of the pivot table part will the style apply to. The differential style of the part. The final displayed style is done by composing all differential styles that overlap the element. An API for setting style of parts consisting of , e.g. grand totals. The enumerator enumerates only existing formats, it doesn't add them. Get styling object for specified . Which part do we want style for? An API to inspect/modify style of the . When is passed as an argument. An API for modifying the pivot table styles that affect whole . Get style formats of a grand total column in a pivot table (i.e. the right column a pivot table). Get style formats of a grand total row in a pivot table (i.e. the bottom row of a pivot table). A fluent API for styling a field of a . Adds a limitation so the is only applied to cells in a pivot table that also belong to the (label or data). Only cells in a pivot table under this field will be styled. Adds a limitation so the is only applied to cells in a pivot table that also belong to the data cells. The cell values also must satisfy the . The pivot style is bound by the field index in a pivot table, not field value. E.g. if field values are Jan, Feb and the predicate marks Feb (offset 1) = second field (Feb) will be highlighted. If user later reverses order in Excel to Feb, Jan, the style would still apply to the second value - Jan. Only cells in a pivot table under this field will be styled. A predicate to determine which index of the field should be styled. Adds a limitation so the is only applied to cells in a pivot table that display values for cells (i.e. data cells and grand total). One of value fields of the pivot table. A base class for pivot styling API. It has takes a selected and applies the style using .Style* API. The derived classes are responsible for exposing API so user can define an area and then create the desired area (from what user specified) through method. An API for grand totals from . A list of references that specify which data cells will be styled. A data cell will be styled, if it lies on all referenced fields. The term "lie on" means that either column or a row of data cell intersects a label cell of referenced field. Enum describing how is a pivot field values (i.e. in data area) displayed. [ISO-29500] 18.18.70 ST_ShowDataAs Field values are displayed normally. Basically a relative importance of a value. Closer the value to 1.0 is, the less important it is. Calculated as (value-in-cell * grand-total-of-grand-totals) / (grand-total-row * grand-total-column). Some calculation from need a value as another an argument of a calculation (e.g. difference from). This enum specifies how to find the reference value. An enum that specifies how are grouped pivot field values summed up in a single cell of a pivot table. [ISO-29500] 18.18.17 ST_DataConsolidateFunction Values are summed up. A pivot value field, it is basically a specification of how to determine and format values from source to display in the pivot table. Specifies the index to the base field when the ShowDataAs calculation is in use. Instead of base item, previous or next value can be used through Used only if the value should be showed Show Values As in the value field settings. The name of the column of the relevant base field. Show values as a percent of a specific value of a different field, e.g. as a % of units sold from Q1 (quarts is a base field and Q1 is a base item). The value of a base item to calculate a value to show in the pivot table. The base item is selected from values of a base field. Returns blank, when value can't be determined. Used only if the value should be showed Show Values As in the value field settings. The value of the referenced base field item. Show values as a percent of a specific value of a different field, e.g. as a % of units sold from Q1 (quarts is a base field and Q1 is a base item). Get custom name of pivot value. If custom name is not specified, return source name as a fallback. An interface for fluent configuration of how to show , when the value should be displayed not as a value itself, but in relation to another value (e.g. percentage difference in relation to different value). The base item value for calculation will be the value of the previous row of base field, depending on the order of base field values in a row/column. If there isn't a previous value, the same value will be used. This only affects display how are values displayed, not the values themselves. Example: We have a table of sales and a pivot table, where sales are summed per month. The months are sorted from Jan to Dec. To display a percentage increase of sales per month (the base value is previous month): IXLPivotValue sales; sales.SetSummaryFormula(XLPivotSummary.Sum).ShowAsPercentageDifferenceFrom("Month").AndPrevious(); An API for manipulating a format of one data field. Set number formatting using one of predefined codes. Predefined codes are described in the . A numeric value describing how should the number be formatted. Add a new value field to the pivot table. If addition would cause, the field is added to the . The added field will use passed as the . The that is used as a data. Multiple data fields can use same source (e.g. sum and count). Newly added field. Add a new value field to the pivot table. If addition would cause, the field is added to the . The that is used as a data. Multiple data fields can use same source (e.g. sum and count). The added data field . Newly added field. A rule describing a subset of pivot table. Used mostly for styling through . [ISO-29500] 18.3.1.68 PivotArea A subset of field values that are part of the pivot area. Index of the field that this selection rule refers to. An area of aspect of pivot table that is part of the pivot area. Flag indicating whether only the data values (in the data area of the view) for an item selection are selected and does not include the item labels. Can't be set with together with . Flag indicating whether only the item labels for an item selection are selected and does not include the data values(in the data area of the view). Can't be set with together with . Flag indicating whether the row grand total is included. Flag indicating whether the column grand total is included. Flag indicating whether indexes refer to fields or items in the pivot cache and not the view. Flag indicating whether the rule refers to an area that is in outline mode. A reference that specifies a subset of the selection area. Points are relative to the top left of the selection area. Flag indicating if collapsed levels/dimensions are considered subtotals. The region of the pivot table to which this rule applies. Position of the field within the axis to which this rule applies. An area of aspect of pivot table that is part of the . [ISO-29500] 18.18.58 ST_PivotAreaType Length is a number of fields, in same order as . Number of fields in the cache. Pivot cache definition id from the file. A source of the in the cache. Can be used to refresh the cache. May not always be available (e.g. external source) Try to get a field index for a field name. Name of the field. The found index, start at 0. True if source contains the field. Try to find an existing pivot cache for the passed area. The area is checked against both types of source references (tables and ranges) and if area matches, the cache is returned. A list of in the pivot table cache definition. Generally, it contains all strings of the field records (record just indexes them through ) and also values used directly in pivot table (e.g. filter field reference the table definition, not record). Shared items can't contain . Storage of strings to save 8 bytes per XLPivotCacheValue (reference can't be aliased with a number). Strings in a pivot table are case-insensitive. Get index of value or -1 if not among shared items. A page filter for pivot table that uses as the source of data. It is basically a container of strings that are displayed in a page filter above the pivot table. Page items (=names) displayed in the filter. The value is referenced through index by . One of ranges that form a source for a . Indexes into the . If the value is null and page filter exists, it is displayed as a blank. There can be at most 4 indexes, because there can be at most 4 page filters. If range set is from another workbook, a relationship id to the workbook from cache definition. Represents a single value in a pivot cache record. A memory used to hold value of a . Its interpretation depends on the type. It doesn't hold value for strings directly, because GC doesn't allow aliasing same 8 bytes for number or references. For strings, it contains an index to a string storage array that is stored separately. All values of a cache field for a pivot table. Get or add a value to the shared items. Throw, if value is not in items. Index in shared items. Is among the value among values of the record. Statistics about a pivot cache field values. These statistics are available, even if cache field doesn't have any record values. Are all numbers in the field integers? Doesn't have to fit into int32/64, just no fractions. Does field contain any string, boolean or error? Is any text longer than 255 chars? Is any value DateTime or TimeSpan? TimeSpan is converted to 1899-12-31TXX:XX:XX date. An enum that represents types of values in pivot cache records. It represents values under CT_Record type. A blank value. Keep at 0 so newly allocated arrays of values have a value of missing. Double precision number, not NaN or infinity. Bool value. value. Cache value is a string. Because references can't be converted to number (GC would not accept it), the value is an index into a table of strings in the cache. Value is a date time. Although the value can be in theory csd:dateTime (i.e. with offsets and zulu), the time offsets are not permitted (Excel refused to load cache data) and zulu is ignored. Value is a reference to the shared item. The index value is an index into the shared items array of the field. Specifies how to apply conditional formatting rule on a pivot table . Avoid if possible, doesn't seem to work and row/column causes Excel to repair file. 18.18.84 ST_Type. Defines a scope of conditional formatting applied to . The scope is more of a "user preference", it doesn't determine actual scope. The actual scope is determined by . The scope determines what is in GUI and when reapplied, it updates the according to selected values. 18.18.67 ST_Scope Conditional formatting is applied to selected cells. When scope is applied, CF areas are be updated to contain currently selected cells in GUI. Conditional formatting is applied to selected data fields. When scope is applied, CF areas are be updated to contain data fields of selected cells in GUI. Conditional formatting is applied to selected pivot fields intersections. When scope is applied, CF areas are be updated to contain row/column intersection of currently selected cell in GUI. Specification of conditional formatting of a pivot table. An option to display in GUI on how to update . A rule that determines how should CF be applied to . Doesn't seem to work, Excel has no dialogue, nothing found on web and Excel tries to repair on row/column values. Avoid if possible. Areas of pivot table the rule should be applied. The areas are projected to the sheet that Excel actually uses to display CF. Conditional format applied to the . The of the format is used as a identifier used to connect pivot CF element and sheet CF element. Pivot CF is ultimately part of sheet CFs and the priority determines order of CF application (note that CF has flag). A description of formatting that should be applied to a . Pivot area that should be formatted. Should the formatting (determined by ) be applied or not? Differential formatting to apply to the . It can be empty, e.g. if is blank. Empty dxf is represented by , until we get better dxf representation. An enum describing if applies formatting to the cells of pivot table or not. [ISO-29500] 18.18.34 ST_FormatAction [MS-OI29500] 2.1.761 Excel does not support the Drill and Formula values for the action attribute. Therefore, neither do we, although Drill and Formula values are present in the ISO ST_FormatAction enum. No format is applied to the pivot table. This is used when formatting is cleared from already formatted cells of pivot table. Pivot table has formatting. This is the default value. A categorization of or . 18.18.43 ST_ItemType (PivotItem Type). > The pivot item represents an "average" aggregate function. The pivot item represents a blank line. The pivot item represents custom the "count numbers" aggregate. The pivot item represents the "count" aggregate function (i.e. number, text and everything else, except blanks). The pivot item represents data. The pivot item represents the default type for this pivot table, i.e. the "total" aggregate function. The pivot items represents the grand total line. The pivot item represents the "maximum" aggregate function. The pivot item represents the "minimum" aggregate function. The pivot item represents the "product" function. The pivot item represents the "standard deviation" aggregate function. The pivot item represents the "standard deviation population" aggregate function. The pivot item represents the "sum" aggregate value. The pivot item represents the "variance" aggregate value. The pivot item represents the "variance population" aggregate value. A field displayed in the filters part of a pivot table. Field index to . Can't contain 'data' field -2. If a single item is selected, item index. Null, if nothing selected or multiple selected. Multiple selected values are indicated directly in through flags. Items that are not selected are hidden, rest isn't. Represents a set of selected fields and selected items within those fields. It's used to select an area for . If is false, then it is index into pivot fields items of pivot field (unless is true). If is true, then it is index into shared items of a cached field with index (unless is true). Specifies the index of the field to which this filter refers. A value of -2/4294967294 indicates the 'data' field. It can represent pivot field or cache field, depending on . Flag indicating whether this field has selection. This attribute is used when the pivot table is in outline view. It is also used when both header and data cells have selection. Flag indicating whether the item in is referred to by position rather than item index. Flag indicating whether the item is referred to by a relative reference rather than an absolute reference. This attribute is used if posRef is set to true. Source of data for a that takes data from a connection to external source of data (e.g. database or a workbook). Source of data for a that takes uses a union of multiple scenarios in the workbook to create data. Will application automatically create additional page filter in addition to the . Custom page filters that toggle whether to display data from a particular range set. There can be 0..4 page filters. Each can have a different combination of range sets. Example: The range sets are months and one page is Q1,Q2,Q3,Q4 and second page filter is Last month of quarter and Other months. These page items are referenced by . Range sets that consists the cache source. Source of data for a that takes data from external workbook. External workbook relId. If relationships of cache definition changes, make sure to either keep same or update it. Are source data in external workbook defined by a or by cell area. A table or defined name in an external workbook that contains source data. An area in an external workbook that contains source data. A reference to the source data of . The source might exist or not, that is evaluated during pivot cache record refresh. Are source data in external workbook defined by a or by cell area. Book area with the source data. Either this or is set. Name of a table or a book-scoped named range that contain the source data. Either this or is set. Try to determine actual area of the source reference in the workbook. Source reference might not be valid in the workbook. Source of data for a that takes uses scenarios in the workbook to create data. List of all fields in the pivot table, roughly represents pivotTableDefinition. pivotFields. Contains info about each field, mostly page/axis info (data field can reference same field multiple times, so it mostly stores data in data fields). Table theme this pivot table will use. All fields reflected in the pivot cache. Order of fields is same as for in the . Part of the pivot table style. Area of a pivot table. Area doesn't include page fields, they are above the area with one empty row between area and filters. First row of pivot table header, relative to the . First row of pivot table data area, relative to the . First column of pivot table data area, relative to the . Determines the whether 'data' field is on (true) or (false). Determines the default 'data' field position, when it is automatically added to row/column fields. 0 = first (e.g. before all column/row fields), 1 = second (i.e. after first row/column field) and so on. > number of fields or null indicates the last position. An identification of legacy table auto-format to apply to the pivot table. The Apply*Formats properties specifies which parts of auto-format to apply. If null or is not true, legacy auto-format is not applied. The value must be less than 21 or greater than 4096 and less than or equal to 4117. See ISO-29500 Annex G.3 for how auto formats look like. If auto-format should be applied ( and are set), apply legacy auto-format number format properties. If auto-format should be applied ( and are set), apply legacy auto-format border properties. If auto-format should be applied ( and are set), apply legacy auto-format font properties. If auto-format should be applied ( and are set), apply legacy auto-format pattern properties. If auto-format should be applied ( and are set), apply legacy auto-format alignment properties. If auto-format should be applied ( and are set), apply legacy auto-format width/height properties. Initial text of 'data' field. This is doesn't do anything, Excel always displays dynamically a text 'Values', translated to current culture. Text to display when in cells that contain error. Flag indicating if should be shown when cell contain an error. Test to display for missing items, when is true. Flag indicating if should be shown when cell has no value. Doesn't seem to work in Excel. Name of style to apply to items headers in . Doesn't seem to work in Excel. Name of a style to apply to the cells left blank when a pivot table shrinks during a refresh operation. Version of the application that last updated the pivot table. Application-dependent. Minimum version of the application required to update the pivot table. Application-dependent. OLAP related. Should field items be displayed on the axis despite pivot table not having any value field? true will display items even without data field, false won't. Example: There is an empty pivot table with no value fields. Add field 'Name' to row fields. Should names be displayed on row despite not having any value field? Also called ShowItems Flag indicating if user is allowed to edit cells in data area. Flag indicating if UI to modify the fields of pivot table is disabled. In Excel, the whole field area is hidden. OLAP only. OLAP only. A flag indicating whether a page field that has selected multiple items (but not necessarily all) display "(multiple items)" instead of "All"? If value is false. page fields will display "All" regardless of whether only item subset is selected or all items are selected. Doesn't seem to do anything. Should hide drop down filters. A flag indicating whether UI should display collapse/expand (drill) buttons in pivot table axes. Also called ShowDrill. A flag indicating whether collapse/expand (drill) buttons in pivot table axes should be printed. Also called PrintDrill. OLAP only. Also called ShowMemberPropertyTips. A flag indicating whether UI should display a tooltip on data items of pivot table. The tooltip contain info about value field name, row/col items used to aggregate the value ect. Note that this tooltip generally hides cell notes, because mouseover displays data tool tip, rather than the note. Also called ShowDataTips. A flag indicating whether UI should provide a mechanism to edit the pivot table. If the value is false, Excel provides ability to refresh data through context menu, but ribbon or other options to manipulate field or pivot table settings are not present. Also called enableWizard. Likely OLAP only. Do not confuse with collapse/expand buttons. A flag indicating whether the user is prevented from displaying PivotField properties. Not very consistent in Excel, e.g. can't display field properties through context menu of a pivot table, but can display properties menu through context menu in editing wizard. A flag that indicates whether the formatting applied by the user to the pivot table cells is preserved on refresh. Once again, ISO-29500 is buggy and says the opposite. Also called PreserveFormatting A flag that indicates whether legacy auto formatting has been applied to the PivotTable view. Also called UseAutoFormatting. Also called PageWrap. Also called PageOverThenDown. A flag that indicates whether hidden pivot items should be included in subtotal calculated values. If true, data for hidden items are included in subtotals calculated values. If false, hidden values are not included in subtotal calculations. Also called SubtotalHiddenItems. OLAP only. Option in Excel is grayed out and does nothing. The option is un-grayed out when pivot cache is part of data model. A flag indicating whether grand totals should be displayed for the PivotTable rows. Also called RowGrandTotals. A flag indicating whether grand totals should be displayed for the PivotTable columns. Also called ColumnGrandTotals. A flag indicating whether when a field name should be printed on all pages. Also called FieldPrintTitles. A flag indicating whether whether PivotItem names should be repeated at the top of each printed page (e.g. if axis item spans multiple pages, it will be repeated an all pages). Also called ItemPrintTitles. A flag indicating whether row or column titles that span multiple cells should be merged into a single cell. Useful only in in tabular layout, titles in other layouts don't span across multiple cells. Also called MergeItem. A flag indicating whether UI for the pivot table should display large text in field drop zones when there are no fields in the data region (e.g. Drop Value Fields Here). Only works in legacy layout mode (i.e. is true). Specifies the version of the application that created the pivot cache. Application-dependent. Also called CreatedVersion. A row indentation increment for row axis when pivot table is in compact layout. Units are characters. Also called Indent. A flag indicating whether to include empty rows in the pivot table (i.e. row axis items are blank and data items are blank). Also called ShowEmptyRow. A flag indicating whether to include empty columns in the table (i.e. column axis items are blank and data items are blank). Also called ShowEmptyColumn. A flag indicating whether to show field names on axis. The axis items are still displayed, only field names are not. The dropdowns next to the axis field names are also displayed/hidden based on the flag. Also called ShowHeaders. A flag indicating whether new fields should have their flag set to true. By new, it means field added to page, axes or data fields, not a new field from cache. A flag indicating whether new fields should have their flag set to true. By new, it means field added to page, axes or data fields, not a new field from cache. A flag that indicates whether 'data'/-2 fields in the PivotTable should be displayed in outline next column of the sheet. This is basically an equivalent of property for the 'data' fields, because 'data' field is implicit. When true, the labels from the next field (as ordered by for row or column) are displayed in the next column. Has no effect if 'data' field is last field. Doesn't seem to do much in column axis, only in row axis. Also, Excel sometimes seems to favor flag instead (likely some less used paths in the Excel code). A flag that indicates whether 'data'/-2 fields in the PivotTable should be displayed in compact mode (=same column of the sheet). This is basically an equivalent of property for the 'data' fields, because 'data' field is implicit. When true, the labels from the next field (as ordered by for row or column) are displayed in the same column (one row below). Has no effect if 'data' field is last field. Doesn't seem to do much in column axis, only in row axis. Also, Excel sometimes seems to favor flag instead (likely some less used paths in the Excel code). A flag that indicates whether data fields in the pivot table are published and available for viewing in a server rendering environment. No idea what this does. Likely flag for other components that display table on a web page. A flag that indicates whether to apply the classic layout. Classic layout displays the grid zones in UI where user can drop fields (unless disabled through ). Also called GridDropZones. Likely a flag whether immersive reader should be turned off. Not sure if immersive reader was ever used outside Word, though Excel for Web added some support in 2023. A flag indicating whether field can have at most most one filter type used. This flag doesn't allow multiple filters of same type, only multiple different filter types. If false, field can have at most one filter, if user tries to set multiple, previous one is cleared. Also called multipleFieldFilters. Specifies the next pivot chart formatting identifier to use on the pivot table. First actually used identifier should be 1. The format is used in /chartSpace/pivotSource/ fmtId/@val. The text that will be displayed in row header in compact mode. It is next to drop down (if enabled) of a label/values filter for fields (if is set to true). Use localized text Row labels if property is not specified. The text that will be displayed in column header in compact mode. It is next to drop down (if enabled) of a label/values filter for fields (if is set to true). Use localized text Column labels if property is not specified. A flag that controls how are fields sorted in the field list UI. true will display fields sorted alphabetically, false will display fields in the order fields appear in . OLAP data sources always use alphabetical sorting. Also called fieldListSortAscending. A flag indicating whether MDX sub-queries are supported by OLAP data provider of this pivot table. A flag that indicates whether custom lists are used for sorting items of fields, both initially when the PivotField is initialized and the PivotItems are ordered by their captions, and later when the user applies a sort. Also called customSortList. Add field to a specific axis (page/row/col). Only modified , doesn't modify additional info in , or . Refresh cache fields after cache has changed. Is field used by any axis (row, column, filter), but not data. Specifies the number of unused items to allow in a before discarding unused items. The threshold is set automatically based on the number of items. Default behavior. When even one item is unused. When all shared items of a filed are unused. An enum describing how are values of a pivot field are sorted. [ISO-29500] 18.18.28 ST_FieldSortType. Field values are sorted manually. Field values are sorted in ascending order. Field values are sorted in descending order. One field in a . Pivot table must contain field for each entry of pivot cache and both are accessed through same index. Pivot field contains items, which are cache field values referenced anywhere in the pivot table (e.g. caption, axis value ect.). See [OI-29500] 18.10.1.69 pivotField(PivotTable Field) for details. Pivot field item, doesn't contain value, only indexes to shared items. Custom name of the field. [MS-OI29500] Office requires @name to be unique for non-OLAP PivotTables. Ignored by data fields that use . If the value is set, the field must also be in rowFields/colFields/ pageFields/dataFields collection in the pivot table part (otherwise Excel will consider it a corrupt file). [MS-OI29500] In Office, axisValues shall not be used for the axis attribute. Is this field a data field (i.e. it is referenced the pivotTableDefinition. dataFields)? Excel will crash, unless these two things both set correctly. Should the headers be displayed in a same column. This field has meaning only when is set to true. Excel displays the flag in Field settings - Layout & Print - Display labels from next field in the same column. The value doesn't affect anything individually per field. When ALL fields of the pivot table are false, the headers are displayed individually. If ANY field is true, headers are grouped to single column. Are all items expanded? A flag that determines if field is in tabular form (false) or outline form (true). If it is in outline form, the can also switch to form. Excel displays it on Field Settings - Layout & Print as a radio box. A flag that indicates whether to show all items for this field. Insert empty row below every item if the field is row/column axis. The last field in axis doesn't add extra item at the end. If multiple fields in axis have extra item, only once blank row is inserted. Subtotal functions represented in XML. It's kind of convoluted mess, because it represents three possible results: None - Collection is empty. Automatic - Collection contains only . Custom - Collection contains subtotal functions other than . The is ignored in that case, even if it is present. . Excel requires that pivot field contains a item if and only if there is a declared subtotal function. The subtotal items must be kept at the end of the , otherwise Excel will try to repair workbook. Are item labels on row/column axis repeated for each nested item? Also called FillDownLabels. Attribute is ignored if both the and the are true. Attribute is ignored if the field is not on the or the . Add an item when it is used anywhere in the pivot table. Item to add. Index of added item. Filter all shared items of the field through a and return all items that represent a value that satisfies the . The don't necessarily contain all indexes to shared items and if the value is missing in but is present in shared items, add it (that's why method has prefix All). Condition to satisfy. Gets or sets the elements that are allowed to be edited by the user, i.e. those that are not protected. The allowed elements. Adds the specified element to the list of allowed elements. Beware that if you pass through "None", this will have no effect. The element to add Set to true to allow the element or false to disallow the element The current protection instance Allows all elements to be edited. Allows no elements to be edited. Protects all elements. Copies all the protection settings from a different instance. The protectable. Removes the element to the list of allowed elements. Beware that if you pass through "None", this will have no effect. The element to remove The current protection instance Protects this instance without a password. The algorithm. Protects this instance using the specified password and password hash algorithm. The password. The algorithm. Unprotects this instance without a password. Unprotects this instance using the specified password. The password. Gets the algorithm used to hash the password. The algorithm. Gets a value indicating whether this instance is protected with a password. true if this instance is password protected; otherwise, false. Gets a value indicating whether this instance is protected, either with or without a password. true if this instance is protected; otherwise, false. Protects this instance without a password. Protects this instance without a password. Protects this instance with the specified password, password hash algorithm and set elements that the user is allowed to change. The algorithm. The allowed elements. Protects this instance using the specified password and password hash algorithm. The password. The algorithm. Protects this instance with the specified password, password hash algorithm and set elements that the user is allowed to change. The password. The algorithm. The allowed elements. Unprotects this instance without a password. Unprotects this instance using the specified password. The password. Gets a value indicating whether this instance is protected with a password. true if this instance is password protected; otherwise, false. Gets a value indicating whether this instance is protected, either with or without a password. true if this instance is protected; otherwise, false. Protects this instance without a password. Protects this instance using the specified password and password hash algorithm. The password. The algorithm. Unprotects this instance without a password. Unprotects this instance using the specified password. The password. The Windows option is available only in Excel 2007, Excel 2010, Excel for Mac 2011, and Excel 2016 for Mac. Select the Windows option if you want to prevent users from moving, resizing, or closing the workbook window, or hide/unhide windows. Interface for the engine aimed to speed-up the search for the range intersections. Implementation of internally using QuadTree. The minimum number of ranges to be included into a QuadTree. Until it is reached the ranges are added into a simple list to minimize the overhead of searching intersections on small collections. A collection of ranges used before the QuadTree is initialized (until is reached. Generic version of . A very lightweight interface for entities that have an address as a rectangular range. Gets an object with the boundaries of this range. Creates a named range out of these ranges. If the named range exists, it will add these ranges to that named range. The default scope for the named range is Workbook. Name of the range. Creates a named range out of these ranges. If the named range exists, it will add these ranges to that named range. Name of the range. The scope for the named range. Creates a named range out of these ranges. If the named range exists, it will add these ranges to that named range. Name of the range. The scope for the named range. The comments for the named range. Sets the cells' value. If the object is an IEnumerable ClosedXML will copy the collection's data into a table starting from each cell. If the object is a range ClosedXML will copy the range starting from each cell. Setting the value to an object (not IEnumerable/range) will call the object's ToString() method. ClosedXML will try to translate it to the corresponding type, if it can't then the value will be left as a string. The object containing the value(s) to set. Returns the collection of cells. Returns the collection of cells that have a value. Returns the collection of cells that have a value. if set to true will return all cells with a value or a style different than the default. Clears the contents of these ranges. Specify what you want to clear. A behavior of extra outside cells for transpose operation. The option is meaningful only for transposition of non-squared ranges, because squared ranges can always be transposed without effecting outside cells. Shift cells of the smaller side to its direction so there is a space to transpose other side (e.g. if A1:C5 range is transposed, move D1:XFD5 are moved 2 columns to the right). Data of the cells are replaced by the transposed cells. Gets the cell at the specified row and column. The cell address is relative to the parent range. The cell's row. The cell's column. Gets the cell at the specified address. The cell address is relative to the parent range. The cell address in the parent range. Gets the cell at the specified row and column. The cell address is relative to the parent range. The cell's row. The cell's column. Gets the cell at the specified address. The cell address is relative to the parent range. The cell address in the parent range. Gets the specified column of the range. 1-based column number relative to the first column of this range. The relevant column Gets the specified column of the range. Column letter. Gets the first column of the range. Gets the first non-empty column of the range that contains a cell with a value. The options to determine whether a cell is used. The predicate to choose cells. Gets the last column of the range. Gets the last non-empty column of the range that contains a cell with a value. The options to determine whether a cell is used. The predicate to choose cells. Gets a collection of all columns in this range. Gets a collection of the specified columns in this range. The first column to return. 1-based column number relative to the first column of this range. The last column to return. 1-based column number relative to the first column of this range. Gets a collection of the specified columns in this range. The first column to return. The last column to return. The relevant columns Gets a collection of the specified columns in this range, separated by commas. e.g. Columns("G:H"), Columns("10:11,13:14"), Columns("P:Q,S:T"), Columns("V") The columns to return. Returns the first row that matches the given predicate Returns the first row that matches the given predicate Gets the first row of the range. Gets the first non-empty row of the range that contains a cell with a value. The options to determine whether a cell is used. The predicate to choose cells. Gets the last row of the range. Gets the last non-empty row of the range that contains a cell with a value. The options to determine whether a cell is used. The predicate to choose cells. Gets the specified row of the range. 1-based row number relative to the first row of this range. The relevant row Gets a collection of the specified rows in this range. The first row to return. 1-based row number relative to the first row of this range. The last row to return. 1-based row number relative to the first row of this range. Gets a collection of the specified rows in this range, separated by commas. e.g. Rows("4:5"), Rows("7:8,10:11"), Rows("13") The rows to return. Returns the specified range. The range boundaries. Returns the specified range. e.g. Range("A1"), Range("A1:C2") The range boundaries. Returns the specified range. The first cell in the range. The last cell in the range. Returns the specified range. The first cell address in the range. The last cell address in the range. Returns the specified range. The first cell address in the range. The last cell address in the range. Returns a collection of ranges, separated by commas. e.g. Ranges("A1"), Ranges("A1:C2"), Ranges("A1:B2,D1:D4") The ranges to return. Returns the specified range. The first cell's row of the range to return. The first cell's column of the range to return. The last cell's row of the range to return. The last cell's column of the range to return. . Gets the number of rows in this range. Gets the number of columns in this range. Inserts X number of columns to the right of this range. All cells to the right of this range will be shifted X number of columns. Number of columns to insert. Inserts X number of columns to the left of this range. This range and all cells to the right of this range will be shifted X number of columns. Number of columns to insert. Inserts X number of rows on top of this range. This range and all cells below this range will be shifted X number of rows. Number of rows to insert. Inserts X number of rows below this range. All cells below this range will be shifted X number of rows. Number of rows to insert. Deletes this range and shifts the surrounding cells accordingly. How to shift the surrounding cells. Transposes the contents and styles of all cells in this range. How to handle the surrounding cells when transposing the range. Use this range as a table, but do not add it to the Tables list NOTES:
The AsTable method will use the first row of the range as a header row.
If this range contains only one row, then an empty data row will be inserted into the returned table.
Use this range as a table with the passed name, but do not add it to the Tables list Table name to be used. NOTES:
The AsTable method will use the first row of the range as a header row.
If this range contains only one row, then an empty data row will be inserted into the returned table.
Rows used for sorting columns. Automatically updated each time a is called. Columns used for sorting rows. Automatically updated each time a or . User can set desired sorting order here and then call method. Sort rows of the range using the (if non-empty) or by using all columns of the range in ascending order. This method can be used fort sorting, after user specified desired sorting order in . This range. Sort rows of the range according to values in columns specified by . Columns which should be used to sort the range and their order. Columns are separated by a comma (,). The column can be specified either by column number or by column letter. Sort order is parsed case insensitive and can be ASC or DESC. The specified column is relative to the origin of the range. 2 DESC, 1, C asc means sort by second column of a range in descending order, then by first column of a range in and then by column C in ascending order.. What should be the default sorting order or columns in without specified sorting order. When cell value is a , should sorting be case insensitive (false, Excel default behavior) or case sensitive (true). Doesn't affect other cell value types. When true (recommended, matches Excel behavior), blank cell values are always sorted at the end regardless of sorting order. When false, blank values are considered empty strings and are sorted among other cell values with a type . This range. Sort rows of the range according to values in column. Column number that will be used to sort the range rows. Sorting order used by . This range. Sort columns in a range. The sorting is done using the values in each column of the range. In what order should columns be sorted This range. Clears the contents of this range. Specify what you want to clear. Gets the number of columns in the area covered by the range address. Gets or sets the first address in the range. The first address. Gets or sets a value indicating whether this range is valid. true if this instance is valid; otherwise, false. Gets or sets the last address in the range. The last address. Gets the number of cells in the area covered by the range address. Gets the number of rows in the area covered by the range address. Allocates the current range address in the internal range repository and returns it Range of the address or null, if the range is not a valid address. Returns the intersection of this range address with another range address on the same worksheet. The other range address. The intersection's range address Determines whether range address spans the entire column. true if is entire column; otherwise, false. Determines whether range address spans the entire row. true if is entire row; otherwise, false. Determines whether the range address spans the entire worksheet. true if is entire sheet; otherwise, false. Returns a range address so that its offset from the target base address is equal to the offset of the current range address to the source base address. For example, if the current range address is D4:E4, the source base address is A1:C3, then the relative address to the target base address B10:D13 is E14:F14 The source base range address. The target base range address. The relative range Sets a value to every cell in this range. Setter will clear a formula, if the cell contains a formula. If the value is a text that starts with a single quote, setter will prefix the value with a single quote through in Excel too and the value of cell is set to to non-quoted text. Sets the cells' formula with A1 references. Setter trims the formula and if formula starts with an =, it is removed. If the formula contains unprefixed future function (e.g. CONCAT), it will be correctly prefixed (e.g. _xlfn.CONCAT). The formula with A1 references. Create an array formula for all cells in the range. Setter trims the formula and if formula starts with an =, it is removed. If the formula contains unprefixed future function (e.g. CONCAT), it will be correctly prefixed (e.g. _xlfn.CONCAT). When the range overlaps with a table, pivot table, merged cells or partially overlaps another array formula. Sets the cells' formula with R1C1 references. Setter trims the formula and if formula starts with an =, it is removed. If the formula contains unprefixed future function (e.g. CONCAT), it will be correctly prefixed (e.g. _xlfn.CONCAT). The formula with R1C1 references. Gets or sets a value indicating whether this cell's text should be shared or not. If false the cell's text will not be shared and stored as an inline value. Returns the collection of cells. Returns the collection of cells that have a value. Formats are ignored. Returns the collection of cells that have a value. The options to determine whether a cell is used. Searches the cells' contents for a given piece of text The search text. The compare options. if set to true search formulae instead of cell values. Returns the first cell of this range. Returns the first non-empty cell with a value of this range. Formats are ignored. The cell's address is going to be ([First Row with a value], [First Column with a value]) Returns the first non-empty cell with a value of this range. The options to determine whether a cell is used. Returns the first non-empty cell with a value of this range. The options to determine whether a cell is used. The predicate used to choose cells Returns the last cell of this range. Returns the last non-empty cell with a value of this range. Formats are ignored. The cell's address is going to be ([Last Row with a value], [Last Column with a value]) Returns the last non-empty cell with a value of this range. The options to determine whether a cell is used. Determines whether this range contains the specified range (completely). For partial matches use the range.Intersects method. The range address. true if this range contains the specified range; otherwise, false. Determines whether this range contains the specified range (completely). For partial matches use the range.Intersects method. The range to match. true if this range contains the specified range; otherwise, false. Determines whether this range intersects the specified range. For whole matches use the range.Contains method. The range address. true if this range intersects the specified range; otherwise, false. Determines whether this range contains the specified range. For whole matches use the range.Contains method. The range to match. true if this range intersects the specified range; otherwise, false. Unmerges this range. Merges this range. Only the top-left cell will have a value, other values will be blank. Creates/adds this range to workbook scoped . If the named range exists, it will add this range to that named range. Name of the defined name, without sheet. Creates/adds this range to . If the named range exists, it will add this range to that named range. Name of the defined name, without sheet. The scope for the named range. Creates/adds this range to . If the named range exists, it will add this range to that named range. Name of the defined name, without sheet. The scope for the named range. The comments for the named range. Clears the contents of this range. Specify what you want to clear. Deletes the cell comments from this range. Set value to all cells in the range. Converts this object to a range. Determines whether range address spans the entire column. true if is entire column; otherwise, false. Determines whether range address spans the entire row. true if is entire row; otherwise, false. Determines whether the range address spans the entire worksheet. true if is entire sheet; otherwise, false. Returns a data validation rule assigned to the range, if any, or creates a new instance of data validation rule if no rule exists. Creates a new data validation rule for the range, replacing the existing one. Grows this the current range by one cell to each side Grows this the current range by the specified number of cells to each side. The grow count. Shrinks this current range by one cell. Shrinks the current range by the specified number of cells from each side. The shrink count. Returns the intersection of this range with another range on the same worksheet. The other range. Predicate applied to this range's cells. Predicate applied to the other range's cells. The range address of the intersection Returns the set of cells surrounding the current range. The predicate to apply on the resulting set of cells. Calculates the union of two ranges on the same worksheet. The other range. Predicate applied to this range's cells. Predicate applied to the other range's cells. The union Returns all cells in the current range that are not in the other range. The other range. Predicate applied to this range's cells. Predicate applied to the other range's cells. Returns a range so that its offset from the target base range is equal to the offset of the current range to the source base range. For example, if the current range is D4:E4, the source base range is A1:C3, then the relative range to the target base range B10:D13 is E14:F14 The source base range. The target base range. The relative range Gets the cell in the specified row. The cell's row. Returns the specified group of cells, separated by commas. e.g. Cells("1"), Cells("1:5"), Cells("1:2,4:5") The column cells to return. Returns the specified group of cells. The first row in the group of cells to return. The last row in the group of cells to return. Inserts X number of columns to the right of this range. All cells to the right of this range will be shifted X number of columns. Number of columns to insert. Inserts X number of columns to the left of this range. This range and all cells to the right of this range will be shifted X number of columns. Number of columns to insert. Inserts X number of cells on top of this column. This column and all cells below it will be shifted X number of rows. Number of cells to insert. Inserts X number of cells below this range. All cells below this column will be shifted X number of rows. Number of cells to insert. Deletes this range and shifts the cells at the right. Deletes this range and shifts the surrounding cells accordingly. How to shift the surrounding cells. Gets this column's number in the range Gets this column's letter in the range Clears the contents of this column. Specify what you want to clear. Adds a column range to this group. The column range to add. Returns the collection of cells. Returns the collection of cells that have a value. Returns the collection of cells that have a value. The options to determine whether a cell is used. Deletes all columns and shifts the columns at the right of them accordingly. Clears the contents of these columns. Specify what you want to clear. Gets the cell in the specified column. The cell's column. Gets the cell in the specified column. The cell's column. Returns the specified group of cells, separated by commas. e.g. Cells("1"), Cells("1:5"), Cells("1:2,4:5") The row's cells to return. Returns the specified group of cells. The first column in the group of cells to return. The last column in the group of cells to return. Returns the specified group of cells. The first column in the group of cells to return. The last column in the group of cells to return. Inserts X number of cells to the right of this row. All cells to the right of this row will be shifted X number of columns. Number of cells to insert. Inserts X number of cells to the left of this row. This row and all cells to the right of it will be shifted X number of columns. Number of cells to insert. Inserts X number of rows on top of this row. This row and all cells below it will be shifted X number of rows. Number of rows to insert. Inserts X number of rows below this row. All cells below this row will be shifted X number of rows. Number of rows to insert. Deletes this range and shifts the cells below. Deletes this range and shifts the surrounding cells accordingly. How to shift the surrounding cells. Gets this row's number in the range Clears the contents of this row. Specify what you want to clear. Adds a row range to this group. The row range to add. Returns the collection of cells. Returns the collection of cells that have a value. Returns the collection of cells that have a value. The options to determine whether a cell is used. Deletes all rows and shifts the rows below them accordingly. Clears the contents of these rows. Specify what you want to clear. Adds the specified range to this group. The range to add to this group. Removes the specified range from this group. The range to remove from this group. Removes ranges matching the criteria from the collection, optionally releasing their event handlers. Criteria to filter ranges. Only those ranges that satisfy the criteria will be removed. Null means the entire collection should be cleared. Specify whether or not should removed ranges be unsubscribed from row/column shifting events. Until ranges are unsubscribed they cannot be collected by GC. Filter ranges from a collection that intersect the specified address. Is much more efficient that using Linq expression .Where(). Filter ranges from a collection that intersect the specified address. Is much more efficient that using Linq expression .Where(). Filter ranges from a collection that intersect the specified cell. Is much more efficient that using Linq expression .Where(). Creates a new data validation rule for the ranges collection, replacing the existing ones. Creates a named range out of these ranges. If the named range exists, it will add these ranges to that named range. The default scope for the named range is Workbook. Name of the range. Creates a named range out of these ranges. If the named range exists, it will add these ranges to that named range. Name of the range. The scope for the named range. Creates a named range out of these ranges. If the named range exists, it will add these ranges to that named range. Name of the range. The scope for the named range. The comments for the named range. Sets the cells' value. Setter will clear a formula, if the cell contains a formula. If the value is a text that starts with a single quote, setter will prefix the value with a single quote through in Excel too and the value of cell is set to to non-quoted text. Returns the collection of cells. Returns the collection of cells that have a value. Returns the collection of cells that have a value. The options to determine whether a cell is used. Clears the contents of these ranges. Specify what you want to clear. Create a new collection of ranges which are consolidated version of source ranges. Column or row number whose values will be used for sorting. Sorting order. When true (recommended, matches Excel behavior), blank cell values are always sorted at the end regardless of sorting order. When false, blank values are considered empty strings and are sorted among other cell values with a type . When cell value is a , should sorting be case insensitive (false, Excel default behavior) or case sensitive (true). Doesn't affect other cell value types. A comparator of two cell value. It uses semantic of a sort feature in Excel: Order by type is number, text, logical, error, blank. Errors are not sorted. Blanks are always last, both in ascending and descending order. Stable sort. A comparer of rows in a range. It uses semantic of a sort feature in Excel. The comparer should work separate from data, but it would necessitate to sort over . That would require to not only instantiate a new object for each sorted row, but since , it would also be be tracked in range repository, slowing each subsequent operation. To improve performance, comparer has reference to underlaying data and compares row numbers that can be stores in a single allocated array of indexes. Lead a range address to a normal form - when points to the top-left address and points to the bottom-right address. Does this range contains whole another range? The direct constructor should only be used in . Engine for ranges consolidation. Supports IXLRanges including ranges from either one or multiple worksheets. Class representing the area covering ranges to be consolidated as a set of bit matrices. Does all the dirty job of ranges consolidation. Constructor. Current worksheet. Ranges to be consolidated. They are expected to belong to the current worksheet, no check is performed. Get consolidated ranges equivalent to the input ones. Indicates whether the current object is equal to another object of the same type. true if the current object is equal to the parameter; otherwise, false. An object to compare with this object. Indicates whether this instance and a specified object are equal. true if and this instance are the same type and represent the same value; otherwise, false. Another object to compare to. Returns the hash code for this instance. A 32-bit signed integer that is the hash code for this instance. The direct constructor should only be used in . Normally, XLRanges collection includes ranges from a single worksheet, but not necessarily. Removes ranges matching the criteria from the collection, optionally releasing their event handlers. Criteria to filter ranges. Only those ranges that satisfy the criteria will be removed. Null means the entire collection should be cleared. Specify whether or not should removed ranges be unsubscribed from row/column shifting events. Until ranges are unsubscribed they cannot be collected by GC. Filter ranges from a collection that intersect the specified address. Is much more efficient that using Linq expression .Where(). Filter ranges from a collection that intersect the specified address. Is much more efficient that using Linq expression .Where(). Replace the text and formatting of this text by texts and formatting from the text. Original to copy from. This text. How many rich strings is the formatted text composed of. Length of the whole formatted text. Get text of the whole formatted text. Does this text has phonetics? Unlike accessing the property, this method doesn't create a new instance on access. Get or create phonetics for the text. Use to check for existence to avoid unnecessary creation. Add a phonetic run above a base text. Phonetic runs can't overlap. Text to display above a section of a base text. Can't be empty. Index of a first character of a base text above which should be displayed. Valid values are 0..length-1. The excluded ending index in a base text (the hint is not displayed above the end). Must be > . Valid values are 1..length. Remove all phonetic runs. Keeps font properties. Reset font properties to the default font of a container (likely IXLCell). Keeps phonetic runs, and . Number of phonetic runs above the base text. Font used for a new rich text run, never modified. It is generally provided by a container of the formatted text. This method is called every time the formatted text is changed (new runs, font props, phonetics...). A class for holding in a . It's immutable (keys in reverse dictionary can't change) and more memory efficient than mutable rich text. A text of a whole rich text, without styling. Individual rich text runs that make up the , in ascending order, non-overlapping. All phonetics runs of rich text. Empty array, if no phonetic run. In ascending order, non-overlapping. Properties used to display phonetic runs. Create an immutable rich text with same content as the original . Phonetic runs can't overlap and must be in order (i.e. start index must be ascending). Text that is displayed above a segment indicating how should segment be read. Starting index of displayed phonetic (first character is 0). End index, excluding (the last index is a length of the rich text). Properties of phonetic runs. All phonetic runs of a rich text have same font and other properties. Font used for text of phonetic runs. All phonetic runs use same font. There can be no phonetic runs, but with specified font (e.g. the mutable API has only specified font, but no text yet). Type of phonetics. Default is Alignment of phonetics. Default is Copy ctor to return user modifiable rich text from immutable rich text stored in the shared string table. Gets or sets the height of this row. The width of this row in points. Clears the height for the row and defaults it to the spreadsheet row height. Deletes this row and shifts the rows below this one accordingly. Don't use in a loop due to poor performance. Use instead. Gets this row's number Inserts X number of rows below this one. All rows below will be shifted accordingly. The number of rows to insert. Inserts X number of rows above this one. This row and all below will be shifted accordingly. The number of rows to insert. Adjusts the height of the row based on its contents, starting from the startColumn. The column to start calculating the row height. Adjusts the height of the row based on its contents, starting from the startColumn and ending at endColumn. The column to start calculating the row height. The column to end calculating the row height. Adjust height of the column according to the content of the cells. Number of a first column whose content is considered. Number of a last column whose content is considered. Minimum height of adjusted column, in points. Maximum height of adjusted column, in points. Hides this row. Unhides this row. Gets a value indicating whether this row is hidden or not. true if this row is hidden; otherwise, false. Gets or sets the outline level of this row. The outline level of this row. Adds this row to the next outline level (Increments the outline level for this row by 1). Adds this row to the next outline level (Increments the outline level for this row by 1). If set to true the row will be shown collapsed. Sets outline level for this row. The outline level. Sets outline level for this row. The outline level. If set to true the row will be shown collapsed. Adds this row to the previous outline level (decrements the outline level for this row by 1). Adds this row to the previous outline level (decrements the outline level for this row by 1). If set to true it will remove this row from all outline levels. Show this row as collapsed. Gets the cell in the specified column. The cell's column. Gets the cell in the specified column. The cell's column. Returns the specified group of cells, separated by commas. e.g. Cells("1"), Cells("1:5"), Cells("1,3:5") The row's cells to return. Returns the specified group of cells. The first column in the group of cells to return. The last column in the group of cells to return. Returns the specified group of cells. The first column in the group of cells to return. The last column in the group of cells to return. Expands this row (if it's collapsed). Adds a horizontal page break after this row. Clears the contents of this row. Specify what you want to clear. Sets the height of all rows. The height of all rows. Deletes all rows and shifts the rows below them accordingly. Adjusts the height of all rows based on its contents. Adjusts the height of all rows based on its contents, starting from the startColumn. The column to start calculating the row height. Adjusts the height of all rows based on its contents, starting from the startColumn and ending at endColumn. The column to start calculating the row height. The column to end calculating the row height. Hides all rows. Unhides all rows. Increments the outline level of all rows by 1. Increments the outline level of all rows by 1. If set to true the rows will be shown collapsed. Sets outline level for all rows. The outline level. Sets outline level for all rows. The outline level. If set to true the rows will be shown collapsed. Decrements the outline level of all rows by 1. Decrements the outline level of all rows by 1. If set to true it will remove the rows from all outline levels. Show all rows as collapsed. Expands all rows (if they're collapsed). Returns the collection of cells. Returns the collection of cells that have a value. Returns the collection of cells that have a value. The options to determine whether a cell is used. Adds a horizontal page break after these rows. Clears the contents of these rows. Specify what you want to clear. Don't use directly, use properties. The direct constructor should only be used in . Distance in pixels from the bottom of the cells in the current row to the typographical baseline of the cell content if, hypothetically, the zoom level for the sheet containing this row is 100 percent and the cell has bottom-alignment formatting. If the attribute is set, it sets customHeight to true even if the customHeight is explicitly set to false. Custom height means no auto-sizing by Excel on load, so if row has this attribute, it stops Excel from auto-sizing the height of a row to fit the content on load. Should cells in the row display phonetic? This doesn't actually affect whether the phonetic are shown in the row, that depends entirely on the property of a cell. This property determines whether a new cell in the row will have it's phonetic turned on (and also the state of the "Show or hide phonetic" in Excel when whole row is selected). Default is false. Does row have an individual height or is it derived from the worksheet ? Flag enum to save space, instead of wasting byte for each flag. Create a new instance of . If worksheet is specified it means that the created instance represents all rows on a worksheet so changing its height will affect all rows. Default style to use when initializing child entries. A predefined enumerator of to support lazy initialization. Evaluate a cells with a formula and save the calculated value along with the formula. True - formulas are evaluated and the calculated values are saved to the file. If evaluation of a formula throws an exception, value is not saved but file is still saved. False (default) - formulas are not evaluated and the formula cells don't have their values saved to the file. Gets or sets the filter privacy flag. Set to null to leave the current property in saved workbook unchanged Copy this sparkline group to the specified worksheet The worksheet to copy this sparkline group to Create a new sparkline The sparkline group to add the sparkline to The cell to place the sparkline in The range the sparkline gets data from The worksheet this sparkline group is associated with Add a new sparkline group copied from an existing sparkline group to the specified worksheet The worksheet the sparkline group is being added to The sparkline group to copy from The new sparkline group added Add a new sparkline group copied from an existing sparkline group to the specified worksheet The new sparkline group added Add a new sparkline group copied from an existing sparkline group to the specified worksheet The new sparkline group added Add a new sparkline group copied from an existing sparkline group to the specified worksheet The new sparkline group added Add a sparkline to the group. The cell to add sparklines to. If it already contains a sparkline it will be replaced. The range the sparkline gets data from A newly created sparkline. Copy the details from a specified sparkline group The sparkline group to copy from Remove all sparklines in the specified cell from this group The cell to remove sparklines from Remove the sparkline from this group Remove all sparklines from this group Add a new sparkline group to the specified worksheet The worksheet the sparkline group is being added to The new sparkline group added Add empty sparkline group. Add the sparkline group to the collection. The sparkline group to add to the collection The same sparkline group Add a copy of an existing sparkline group to the specified worksheet The sparkline group to copy The worksheet the sparkline group is being added to The new sparkline group added Copy this sparkline group to a different worksheet The worksheet to copy the sparkline group to Search for the first sparkline that is in the specified cell The cell to find the sparkline for The sparkline in the cell or null if no sparklines are found Find all sparklines located in a given range The range to search The sparkline in the cell or null if no sparklines are found Remove all sparklines in the specified cell The cell to remove sparklines from Remove the sparkline group from the worksheet The sparkline group to remove Remove the sparkline from the worksheet The sparkline to remove Remove all sparkline groups and their contents from the worksheet. Shift address of all sparklines to reflect inserted columns before a range. Range before which will the columns be inserted. Has same worksheet. How many columns, can be positive or negative number. Shift address of all sparklines to reflect inserted rows before a range. Range before which will the rows be inserted. Has same worksheet. How many rows, can be positive or negative number. Returns a value that indicates whether two objects have different values. The first value to compare. The second value to compare. true if and are not equal; otherwise, false. Returns a value that indicates whether the values of two objects are equal. The first value to compare. The second value to compare. true if the and parameters have the same value; otherwise, false. Indicates whether the current object is equal to another object of the same type. An object to compare with this object. true if the current object is equal to the other parameter; otherwise, false. Determines whether the specified object is equal to the current object. The object to compare with the current object. true if the specified object is equal to the current object; otherwise, false. Serves as the default hash function. A hash code for the current object. VML palette entries from MS-OI29500. Excel uses Windows system color scheme to determine the actual colors of a palette entry, but we have no way to get them. Win10 doesn't even have a tool, use Classic Color Panel. We will use the default values that are default on Windows. Create a color from RBG hexa number. Alpha will be always set to full opacity. Parse a color in a RRGGBB hexadecimal format. It is used to parse colors of ST_HexColorRGB type from the XML. A 6 character long hexadecimal number. Parsed color with full opacity. Parse VML ST_ColorType type from ECMA-376, Part 4 §20.1.2.3. Gets or sets the cell's horizontal alignment. Gets or sets the cell's vertical alignment. Gets or sets the cell's text indentation. Gets or sets whether the cell's last line is justified or not. Gets or sets the cell's reading order. Gets or sets the cell's relative indent. Gets or sets whether the cell's font size should decrease to fit the contents. Gets or sets the cell's text rotation in degrees. Allowed values are -90 (text is rotated clockwise) to 90 (text is rotated counterclockwise) and 255 for vertical layout of a text. Gets or sets whether the cell's text should wrap if it doesn't fit. Gets or sets whether the cell's text should be displayed from to to bottom (as opposed to the normal left to right). ASCII character set. System default character set. Symbol character set. Characters used by Macintosh. Japanese character set. Korean character set. Another common spelling of the Korean character set. Korean character set. Chinese character set used in mainland China. Chinese character set used mostly in Hong Kong SAR and Taiwan. Greek character set. Turkish character set. Vietnamese character set. Hebrew character set. Arabic character set. Baltic character set. Russian character set. Thai character set. Eastern European character set. Extended ASCII character set used with disk operating system (DOS) and some Microsoft Windows fonts. A font theme scheme. Theme has categories of fonts and when the theme changes, texts that are associated with the particular theme scheme are switched to a font of a new theme. Not a part of theme scheme. A major font of a theme, generally used for headings. A minor font of a theme, generally used to body and paragraphs. Defines an expected character set used by the text of this font. It helps Excel to choose a font face, either because requested one isn't present or is unsuitable. Each font file contains a list of charsets it is capable of rendering and this property is used to detect whether the charset of a text matches the rendering capabilities of a font face and is thus suitable. Example: The FontCharSet is XLFontCharSet.Default, but the selected font name is B Mitra that contains only arabic alphabet and declares so in its file. Excel will detect this discrepancy and choose a different font to display the text. The outcome is that text is not displayed with the B Mitra font, but with a different one and user doesn't see persian numbers. To use the B Mitra font, this property must be set to XLFontCharSet.Arabic that would match the font declared capabilities. Due to prevalence of unicode fonts, this property is rarely used. Determines a theme font scheme a text belongs to. If the text belongs to a scheme and user changes theme in Excel, the font of the text will switch to the new theme font. Scheme font has precedence and will be used instead of a set font. Should the text values of a cell saved to the file be prefixed by a quote (') character? Has no effect if cell values is not a . Doesn't affect values during runtime, text values are returned without quote. An interface implemented by workbook elements that have a defined . Editable style of the workbook element. Modification of this property DOES affect styles of child objects as well - they will be changed accordingly. Accessing this property causes a new instance generated so use this property with caution. If you need only _read_ the style consider using property instead. Editable style of the workbook element. Modification of this property DOES NOT affect styles of child objects. Accessing this property causes a new instance generated so use this property with caution. If you need only _read_ the style consider using property instead. Return a collection of ranges that determine outside borders (used by ). Return ranges represented by elements. For one element (e.g. workbook, cell, column), it should return only the element itself. For element that represent a collection of other elements, e.g. , , , it should return range for each element in the collection. Style value representing the current style of the stylized element. The value is updated when style is modified ( is immutable). A callback method called when is changed. It should update style of the stylized descendants of the stylized element. A method that changes the style from original to modified. Create an instance of XLAlignment initializing it with the specified value. Style to attach the new instance to. Style value to use. Create an instance of XLBorder initializing it with the specified value. Container the border is applied to. Style to attach the new instance to. Style value to use. Helper class that remembers outside border state before editing (in constructor) and restore afterwards (on disposing). It presumes that size of the range does not change during the editing, else it will fail. Create an instance of XLFill initializing it with the specified value. Style to attach the new instance to. Style value to use. Create an instance of XLFont initializing it with the specified value. Style to attach the new instance to. Style value to use. Create a new font that is attached to a style and the changes to the font object are propagated to the style. The container style that will be modified by changes of created XLFont. Create a new font. The changes to the object are not propagated to a style. Create an instance of XLNumberFormat initializing it with the specified value. Style to attach the new instance to. Style value to use. The value -1 that is set to , if is set to user-defined format (non-empty string). Number format identifier of predefined format, see . If -1, the format is custom and stored in the . General number format. Id of the number format. Every workbook has built-int formats that start at 0 (General format). The built-int formats are not explicitly written and might differ depending on culture. Custom number formats have a valid and the id is -1. Reference point of date/number formats available. See more at: https://msdn.microsoft.com/en-us/library/documentformat.openxml.spreadsheet.numberingformat.aspx General General 0 0.00 #,##0 #,##0.00 0% 0.00% 0.00E+00 # ?/? # ??/?? #,##0 ,(#,##0) #,##0 ,[Red](#,##0) #,##0.00,(#,##0.00) #,##0.00,[Red](#,##0.00) ##0.0E+0 @ General d/m/yyyy d-mmm-yy d-mmm mmm-yy h:mm tt h:mm:ss tt H:mm H:mm:ss m/d/yyyy H:mm mm:ss [h]:mm:ss mm:ss.0 OOXML specification is missing colon. @ Create an instance of XLProtection initializing it with the specified value. Style to attach the new instance to. Style value to use. To initialize XLStyle.Default only An immutable style value. Combine row and column styles into a combined style. This style is used by non-pinged cells of a worksheet. Base class for any workbook element that has or may have a style. Read-only style property. Get a collection of stylized entities which current entity's style changes should be propagated to. Apply specified style to the container. Style to apply. Whether or not propagate the style to inner ranges. Change the name of a table. Structural references to the table are not updated. If the new table name is already used by other table in the sheet. Clears the contents of this table. Specify what you want to clear. Get field of the table. Name of the field. Field names are case-insensitive. Requested field. Table doesn't contain field. Appends the IEnumerable data elements and returns the range of the new rows. The IEnumerable data. if set to true propagate extra columns' values and formulas. The range of the new rows. Appends the IEnumerable data elements and returns the range of the new rows. The IEnumerable data. if set to true the data will be transposed before inserting. if set to true propagate extra columns' values and formulas. The range of the new rows. Appends the data of a data table and returns the range of the new rows. The data table. if set to true propagate extra columns' values and formulas. The range of the new rows. Appends the IEnumerable data elements and returns the range of the new rows. The table data. if set to true propagate extra columns' values and formulas. The range of the new rows. Replaces the IEnumerable data elements and returns the table's data range. The IEnumerable data. if set to true propagate extra columns' values and formulas. The table's data range. Replaces the IEnumerable data elements and returns the table's data range. The IEnumerable data. if set to true the data will be transposed before inserting. if set to true propagate extra columns' values and formulas. The table's data range. Replaces the data from the records of a data table and returns the table's data range. The data table. if set to true propagate extra columns' values and formulas. The table's data range. Replaces the IEnumerable data elements as a table and the table's data range. The table data. if set to true propagate extra columns' values and formulas. The table's data range. Resizes the table to the specified range address. The new table range. Resizes the table to the specified range address. The range boundaries. Resizes the table to the specified range address. The range boundaries. Resizes the table to the specified range. The first cell in the range. The last cell in the range. Resizes the table to the specified range. The first cell address in the worksheet. The last cell address in the worksheet. Resizes the table to the specified range. The first cell address in the worksheet. The last cell address in the worksheet. Resizes the table to the specified range. The first cell's row of the range to return. The first cell's column of the range to return. The last cell's row of the range to return. The last cell's column of the range to return. Converts the table to an enumerable of dynamic objects Converts the table to a standard .NET System.Data.DataTable Gets the corresponding column for this table field. Includes the header and footer cells The column. Gets the collection of data cells for this field Excludes the header and footer cells The data cells Gets the footer cell for the table field. The footer cell. null, if the table doesn't have set . Gets the header cell for the table field. The header cell.null, if the table doesn't have set . Gets the index of the column (0-based). The index. Gets or sets the name/header of this table field. The corresponding header cell's value will change if you set this. The name. Gets the underlying table for this table field. Gets or sets the totals row formula in A1 format. The totals row formula a1. Gets or sets the totals row formula in R1C1 format. The totals row formula r1 c1. Gets or sets the totals row function. The totals row function. Gets or sets the totals row label (the leftmost cell in the totals row). The totals row label. If the totals row is not displayed for the table. Deletes this table field from the table. Determines whether all cells this table field have a consistent data type. Determines whether all cells this table field have a consistent formula. Determines whether all cells this table field have a consistent style. Rows the specified row. 1-based row number relative to the first row of this range. Returns a subset of the rows The first row to return. 1-based row number relative to the first row of this range. The last row to return. 1-based row number relative to the first row of this range. Clears the contents of this row. Specify what you want to clear. Adds a table row to this group. The row table to add. Returns the collection of cells. Returns the collection of cells that have a value. Returns the collection of cells that have a value. The options to determine whether a cell is used. Clears the contents of these rows. Specify what you want to clear. Clears the contents of these tables. Specify what you want to clear. Generate a non conflicting table name for the workbook Workbook to generate name for "Base Table Name Name for the table The direct constructor should only be used in . Area of the range, including headings and totals, if table has them. Update headers fields and totals fields by data from the cells. Do not add a new fields or names. Area that contains cells with changed values that might affect header and totals fields. A value of a single cell. It contains a value a specific . Structure provides following group of methods: Is* properties to check type (, ...) Get* methods that return the stored value or throw for incorrect type. Explicit operators to convert XLCellValue to a concrete type. It is an equivalent of Get* methods. TryConvert methods to try to get value of a specific type, even if the value is of a different type. Type of the value. Is the type of value Blank? Is the type of value ? Is the type of value ? Is the type of value ? Is the type of value ? Is the type of value ? Is the type of value ? Is the value or or . Creates an from an . If the type of the object has an implicit conversion operator then it is used. Otherwise, the method is used to convert the provided object to a string. The following types and their nullable counterparts are supported without requiring to be converted to a string: The object to convert. An object that supplies culture-specific formatting information. An representation of the object. A function used during data insertion to convert an object to XLCellValue. Try to convert a string into a string value, doing your best. If no other type can be extracted, consider it a text. Text to parse into a value. Culture used to parse numbers. Parsed value. If the value is of type , return , otherwise throw . If the value is of type , return logical, otherwise throw . If the value is of type , return number, otherwise throw . If the value is of type , return text, otherwise throw . If the value is of type , return error, otherwise throw . If the value is of type , return date time, otherwise throw . If the value is of type , return time span, otherwise throw . Get a number, either directly from type number or from serialized time span or serialized date time. If type is not or or . Return text representation of a value in current culture. Return text representation of a value in the specified culture. Is the cell value text and is equal to the ? Text comparison is case sensitive. Get a value, if it is a . True if value was retrieved, false otherwise. Try to convert the value to a and return it. Method succeeds, when value is Type . Type and the text is empty. Try to convert the value to a and return it. Method succeeds, when value is Type . Type , then the value of 0 means false and any other value is true. Type and the value is TRUE or FALSE (case insensitive). Note that calc engine generally doesn't coerce text to logical (e.g. arithmetic operations), though it happens in most function arguments (e.g. IF or AND). Try to convert the value to a and return it. Double value - return the value. Boolean value - return the 0 for TRUE and 1 for FALSE. Text value - use the VALUE semantic to convert a text to a number. DateTime value - return the serial date time number. TimeSpan value - return the serial time span value. Note that the coercion is current culture specific (e.g. decimal separators can differ). The converted value. Result is never infinity or NaN. The culture used to convert the value for texts. Try to convert the value to a and return it. Method succeeds, when value is Type . Type and when the number is interpreted is a serial date time, it falls within the DateTime range. Type and when the number is interpreted is a serial date time, it falls within the DateTime range. Try to convert the value to a and return it. Method succeeds, when value is Type . Type , the number is interpreted is a time span date time. Type and it can be parsed as a time span (accepts even hours over 24 hours). The converted value. The culture used to get time and decimal separators. Functions that are marked with a prefix _xlfn in formulas, but not GUI. Officially, they are called future functions. Up to date for MS-XLSX 26.1 from 2024-12-11. Functions that are marked with a prefix _xlfn._xlws in formulas, but not GUI. They are part of the future functions. Unlike other future functions, they can only be used in a worksheet, but not a macro sheet. In the grammar, they are marked as worksheet-only-function-list. Up to date for MS-XLSX 26.1 from 2024-12-11. Key: GUI name of future function, Value: prefixed name of future function. This doesn't include all future functions, only ones that need a hidden prefix (e.g. ECMA.CEILING is a future function without a prefix). Analyze input string and convert value. For avoid analyzing use escape symbol ' Direct set value. If value has unsupported type - value will be stored as string returned by Behavior for Gets an object to manipulate the worksheets. Gets an object to manipulate this workbook's named ranges. Gets an object to manipulate this workbook's theme. All pivot caches in the workbook, whether they have a pivot table or not. Gets or sets the default style for the workbook. All new worksheets will use this style. Gets or sets the default row height for the workbook. All new worksheets will use this row height. Gets or sets the default column width for the workbook. All new worksheets will use this column width. Gets or sets the default page options for the workbook. All new worksheets will use these page options. Gets or sets the default outline options for the workbook. All new worksheets will use these outline options. Gets or sets the workbook's properties. Gets or sets the workbook's calculation mode. Gets or sets the workbook's reference style. Saves the current workbook. Saves the current workbook and optionally performs validation Saves the current workbook to a file. Saves the current workbook to a file and optionally validates it. Saves the current workbook to a stream. Saves the current workbook to a stream and optionally validates it. Try to find a table with in a workbook. Try to find a table that covers same area as the in a workbook. Searches the cells' contents for a given piece of text The search text. The compare options. if set to true search formulae instead of cell values. Creates a new Excel workbook. Opens an existing workbook from a file. The file to open. Opens an existing workbook from a stream. The stream to open. Force recalculation of all cell formulas. Evaluate a formula and return a value. Formulas with references don't work and culture used for conversion is invariant. Evaluate a formula and return a value. Use current culture. Notify various component of a workbook that sheet has been added. Notify various component of a workbook that sheet is about to be removed. Calculate expected column width as a number displayed in the column in Excel from number of characters that should fit into the width and a font. List of all VML length units and their conversion. Key is a name, value is a conversion function to EMU. See documentation. OI-29500 says Office also uses EMUs throughout VML as a valid unit system. Relative units conversions are guesstimated by how Excel 2022 behaves for inset attribute of TextBox element of a note/comment. Generally speaking, Excel converts relative values to physical length (e.g. px to pt) and saves them as such. The ex/em units are not interpreted as described in the doc, but as 1/90th or an inch. The % seems to be always 0. Parses the cell value for normal or rich text Input element should either be a shared string or inline string The cell. The element (either a shared string or inline string) Loads the conditional formatting. A free id that can be used by the workbook to reference to a pivot cache. The PivotCaches element in a workbook connects the parts with pivot cache parts. A dictionary of extra info for pivot during saving. The key is . A map of shared string ids. The index is the actual index from sharedStringId and value is an mapped stringId to write to a file. The mapped stringId has no gaps between ids. Add all existing rel ids present on the parts or workbook to the generator, so they are not duplicated again. Fake address to be used everywhere the invalid address is needed. Reference to a VML that contains notes, forms controls and so on. All such things are generally unified into a single legacy VML file, set during load/save. The id of a sheet that is unique across the workbook, kept across load/save. The ids of sheets are not reused. That is important for referencing the sheet range/point through sheetId. If sheetIds were reused, references would refer to the wrong sheet after the original sheetId was reused. Excel also doesn't reuse sheetIds. Referencing sheet through non-reused sheetIds means that reference can survive sheet renaming without any changes. Always > 0 (Excel will crash on 0). A cached r:id of the sheet from the file. If the sheet is a new one (not yet saved), the value is null until workbook is saved. Use instead is possible. Mostly for removing deleted sheet parts during save. Address of active cell/cursor in the worksheet. Get cell or null, if cell doesn't exist. Get a range row from the shared repository or create a new one. Address of range row. Style to apply. If null the worksheet's style is applied. Range row with the specified address. Get a range column from the shared repository or create a new one. Address of range column. Style to apply. If null the worksheet's style is applied. Range column with the specified address. Get the actual style for a point in the sheet. Get a style that should be used for a , if the value is set to the . SheetId that will be assigned to next created sheet. Round the number to the integer. A helper method to avoid need to specify the midpoint rounding and casting each time. Round the number to specified number of digits. A helper method to avoid need to specify the midpoint rounding each time. Skip last element of a sequence. Select all that are not null. Get index of highest set bit <= to or -1 if no such bit. Get index of lowest set bit >= to or -1 if no such bit. Get highest set bit index or -1 if no bit is set. Convert a string (containing code units) into code points. Surrogate pairs of code units are joined to code points. UTF-16 code units to convert. Output containing code points. Must always be able to fit whole . Number of code points in the . Is the string a new line of any kind (widnows/unix/mac)? Input text to check for EOL at the beginning. Length of EOL chars. True, if text has EOL at the beginning. Convert a magic text to a number, where the first letter is in the highest byte of the number. Return a string representation of a TimeSpan that can be parsed by an Excel through text-to-number coercion. Excel can convert time span string back to a number, but only if it doesn't has days in the string, only hours. It's an opposite of . Common methods Maximum number of code units that can be stored in a cell. 1900 calendar serial date upper limit (exclusive). 1904 calendar serial date upper limit (exclusive). Comparer used to compare sheet names. Comparer used to compare defined names. Comparer of function names. Gets the column number of a given column letter. The column letter to translate into a column number. Gets the column letter of a given column number. The column number to translate into a column letter. if set to true the column letter will be restricted to the allowed range. An alternative to . In NetFx, it returned a value rounded to milliseconds. In .Net Core 3.0 the behavior has changed and conversion doesn't round at all (=precision down to ticks). To avoid problems with a different behavior on NetFx and Core (saving value 1:12:30 on NetFx machine could become 1:12:29.999999 on Core one machine), we use instead this method for both runtimes (behaves as on Core). TimeSpan has a resolution of 0.1 us (1.15e-12 as a serial date). ~12 digits of precision are needed to accurately represent one day as a serial date time in that resolution. Double has ~15 digits of precision, so it should be able to represent up to ~100 days in a ticks precision. Convert size in pixels to a size in NoC (number of characters). Size in pixels. Size of maximum digit width in pixels. Size in NoC. Convert size in NoC to size in pixels. Size in number of characters. Maximum digit width in pixels. Size in pixels (not rounded). Convert size in number of characters to pixels. Width Font used to determine mdw. Workbook for dpi and graphic engine. Width in pixels. Convert width to pixels. Width from the source file, not NoC that is displayed in Excel as a width. Number of pixels. Convert width (as a multiple of MDWs) into a NoCs (number displayed in Excel). Width in MDWs to convert. Font used to determine MDW. Workbook Width as a number of NoC. Convert degrees to radians. Creates a valid sheet name, which conforms to the following rules. A sheet name: is never null, has minimum length of 1 and maximum length of 31, doesn't contain special chars: (: 0x0000 0x0003 / \ ? * ] [). Sheet names must not begin or end with ' (apostrophe) can be any string, will be truncated if necessary, allowed to be null the char to replace invalid characters. a valid string, "empty" if too short, "null" if null Validates the name of the sheet. The character count MUST be greater than or equal to 1 and less than or equal to 31. The string MUST NOT contain the any of the following characters: - 0x0000 - 0x0003 - colon (:) - backslash(\) - asterisk(*) - question mark(?) - forward slash(/) - opening square bracket([) - closing square bracket(]) The string MUST NOT begin or end with the single quote(') character. Name of the sheet. Get value of attribute with type ST_CellRef. Get value of attribute with type ST_Ref. Extensions method for . Convert area to an absolute sheet range (regardless if the area is A1 or R1C1). Area to convert An anchor address that is the center of R1C1 relative address. Converted absolute range. Write date in a format 2015-01-01T00:00:00 (ignore kind). A reader for BMP for Windows and OS/2. Specification: https://www.fileformat.info/format/bmp/corion.htm https://www.fileformat.info/format/bmp/egff.htm https://www.fileformat.info/format/os2bmp/egff.htm Carlito is a Calibri metric compatible font. This is a version stripped of everything but metric information to keep the embedded file small. It is reasonably accurate for many alphabets (contains 2531 glyphs). It has no glyph outlines, no TTF instructions, no substitutions, glyph positioning ect. It is created from Carlito font through strip-fonts.sh script. A font loaded font in the size . There is no benefit in having multiple allocated instances, everything is just scaled at the moment. Max digit width as a fraction of Em square. Multiply by font size to get pt size. Get a singleton instance of the engine that uses Microsoft Sans Serif as a fallback font. Initialize a new instance of the engine. A name of a font that is used when a font in a workbook is not available. Initialize a new instance of the engine. The engine will be able to use system fonts and fonts loaded from external sources. Useful/necessary for environments without an access to filesystem. A stream that contains a fallback font. Should engine try to use system fonts? If false, system fonts won't be loaded which can significantly speed up library startup. Extra fonts that should be loaded to the engine. Create a default graphic engine that uses only fallback font and additional fonts passed as streams. It ignores all system fonts and that can lead to decrease of initialization time. Font is determined by a name and style in the worksheet, but the font name must be mapped to a font file/stream. System fonts on Windows contain hundreds of font files that have to be checked to find the correct font file for the font name and style. That means to read hundreds of files and parse data inside them. Even though SixLabors.Fonts does this only once (lazily too) and stores data in a static variable, it is an overhead that can be avoided. This factory method is useful in several scenarios: Client side Blazor doesn't have access to any system fonts. Worksheet contains only limited number of fonts. It might be sufficient to just load few fonts we are A stream that contains a fallback font. Fonts that should be loaded to the engine. Create a default graphic engine that uses only fallback font and additional fonts passed as streams. It also uses system fonts. A stream that contains a fallback font. Fonts that should be loaded to the engine. A DPI resolution. Horizontal DPI resolution. Vertical DPI resolution. Metadata read of a vector EMF file. Specification: https://learn.microsoft.com/en-us/openspecs/windows_protocols/ms-emf/ Read info about a GIF file. Gif file has no DPI, only pixel ratio. Specification: https://www.w3.org/Graphics/GIF/spec-gif89a.txt A bounding box for a glyph, in pixels. In most cases, a glyph represents a single unicode code point. In some cases, multiple code points are represented by a single glyph (emojis in most cases). Although data type is float, the actual values should be whole numbers. That best fits to Excel behavior, but there might be some cases in the future, where values can be a floats (e.g. advance could be non-pixels aligned). A special glyph box that indicates a line break. Dimensions are kept at 0, so it doesn't affect any calculations. Advance width in px of a box for code point. Value should be whole number. Size of Em square in pixels. If em is not a square, vertical dimension of em square. Value should be whole number. Distance in px from baseline to the bottom of the box. Descent/height is determined by font, not by codepoints of the glyph. Value should be whole number. Get line width of the glyph box. It is calculated as central band with a text and a lower and an upper bands. Central band (text) has height is em-square - descent and the bands are descent. An interface to abstract away graphical functionality, like reading images, fonts or to determine a width of a text. Get the info about a picture (mostly dimensions). Stream is at the beginning of the image. The expected format of the image. Use for auto detection. Unable to determine picture dimensions or format doesn't match the stream. Get the height of a text with the font in pixels. Should be EMHeight+descent. Get the width of a text in pixels. Do not add any padding, there can be multiple spans of a texts with different fonts in a line. The width of the widest 0-9 digit in pixels. OOXML measures width of a column in multiples of widest 0-9 digit character in a normal style font. Get font descent in pixels (positive value). Excel is using OS/2 WinAscent/WinDescent for TrueType fonts (e.g. Calibri), not a correct font ascent/descent. Get a glyph bounding box for a grapheme cluster. In 99+%, grapheme cluster will be just a codepoint. Method uses grapheme instead, so it can be future-proof signature and have less braking changes. Implementing method by adding widths of individual code points is acceptable. A part of a string in code points (or runes in C# terminology, not UTF-16 code units) that together form a grapheme. Multiple unicode codepoints can form a single glyph, e.g. family grapheme is a single glyph created from 6 codepoints (man, zero-width-join, woman, zero-width-join and a girl). A string can be split into a grapheme clusters through . Font used to determine size of a glyph for the grapheme cluster. A resolution used to determine pixel size of a glyph. Font might be rendered differently at different resolutions. Bounding box containing the glyph. Read JFIF or EXIF. Read info about PCX picture. https://moddingwiki.shikadi.net/wiki/PCX_Format A reader for baseline TIFF. Specification: https://www.itu.int/itudoc/itu-t/com16/tiff-fx/docs/tiff6.pdf II like Intel in ASCII. MM like Motorola in ASCII. Reader of dimensions for WebP image format. Reader of Windows Meta File. https://learn.microsoft.com/en-us/openspecs/windows_protocols/ms-wmf/4813e7fd-52d0-4f42-965f-228c8b7488d2 http://formats.kaitai.io/wmf/index.html Metadata info about a picture. At least one of the sizes (pixels/physical) must be set. Detected format of the image. Size of the picture in pixels. A physical size in 0.01mm. Used by vector images. 0 = use workbook DPI. 0 = use workbook DPI. Parse ARGB color stored in ST_UnsignedIntHex the same way as Excel does. Parse RRGGBB color. Convert color in ClosedXML representation to specified OpenXML type. The descendant of . The existing instance of ColorType. Color in ClosedXML format. Flag specifying that the color should be saved in differential format (affects the transparent color processing). The original color in OpenXML format. Convert color in ClosedXML representation to specified OpenXML type. The descendant of . The existing instance of ColorType. Color in ClosedXML format. Flag specifying that the color should be saved in differential format (affects the transparent color processing). The original color in OpenXML format. Convert color in OpenXML representation to ClosedXML type. Color in OpenXML format. The color in ClosedXML format. Convert color in OpenXML representation to ClosedXML type. Color in OpenXML format. The color in ClosedXML format. Here we perform the actual conversion from OpenXML color to ClosedXML color. OpenXML color. Must be either or . Since these types do not implement a common interface we use dynamic. The color in ClosedXML format. Initialize properties of the existing instance of the color in OpenXML format basing on properties of the color in ClosedXML format. OpenXML color. Must be either or . Since these types do not implement a common interface we use dynamic. Color in ClosedXML format. Flag specifying that the color should be saved in differential format (affects the transparent color processing).