Skip to content

Class ExcelRange

Namespace: OfficeOpenXml
Assembly: EPPlus.dll

A range of cells.

public class ExcelRange : ExcelRangeBase, IEnumerable<ExcelRangeBase>, IEnumerable, IEnumerator<ExcelRangeBase>, IDisposable, IEnumerator

Inheritance

object ← ExcelCellBase ← ExcelAddressBase ← ExcelAddress ← ExcelRangeBase ← ExcelRange

Implements

IDisposable
IEnumerable
IEnumerable<ExcelRangeBase>
IEnumerator
IEnumerator<ExcelRangeBase>

Inherited Members

ExcelAddress.Address
ExcelAddressBase.Address
ExcelAddressBase.AddressAbsolute
ExcelAddressBase.BeforeChangeAddress()
ExcelAddressBase.ChangeAddress()
ExcelAddressBase.Columns
ExcelAddressBase.End
ExcelAddressBase.Equals(object)
ExcelAddressBase.ExternalReferenceIndex
ExcelAddressBase.FullAddress
ExcelAddressBase.GetHashCode()
ExcelAddressBase.IsExternal
ExcelAddressBase.IsFullColumn
ExcelAddressBase.IsFullRow
ExcelAddressBase.IsName
ExcelAddressBase.LocalAddress
ExcelAddressBase.Rows
ExcelAddressBase.SetAddress(string, ExcelWorkbook, string)
ExcelAddressBase.Start
ExcelAddressBase.Table
ExcelAddressBase.ToString()
ExcelAddressBase.Validate()
ExcelCellBase.GetAddress(int, bool, int, bool)
ExcelCellBase.GetAddress(int, int, bool)
ExcelCellBase.GetAddress(int, int, int, int, bool, bool, bool, bool)
ExcelCellBase.GetAddress(int, int, int, int, bool)
ExcelCellBase.GetAddress(int, int, int, int)
ExcelCellBase.GetAddress(int, int)
ExcelCellBase.GetAddressCol(int, bool)
ExcelCellBase.GetAddressRow(int, bool)
ExcelCellBase.GetColumnLetter(int, bool)
ExcelCellBase.GetColumnLetter(int)
ExcelCellBase.GetFullAddress(string, string, string)
ExcelCellBase.GetFullAddress(string, string)
ExcelCellBase.IsSimpleAddress(string)
ExcelCellBase.IsValidAddress(string)
ExcelCellBase.IsValidCellAddress(string)
ExcelCellBase.IsValidRangeAddress(string)
ExcelCellBase.IsValidTableAddress(string)
ExcelCellBase.TranslateFromR1C1(string, int, int)
ExcelCellBase.TranslateToR1C1(string, int, int)
ExcelRangeBase._rtc
ExcelRangeBase._worksheet
ExcelRangeBase.AddComment(string, string)
ExcelRangeBase.AddThreadedComment()
ExcelRangeBase.AutoFilter
ExcelRangeBase.AutoFitColumns()
ExcelRangeBase.AutoFitColumns(double, double)
ExcelRangeBase.AutoFitColumns(double)
ExcelRangeBase.ChangeAddress()
ExcelRangeBase.Clear()
ExcelRangeBase.ClearFormulas()
ExcelRangeBase.ClearFormulaValues()
ExcelRangeBase.Comment
ExcelRangeBase.ConditionalFormatting
ExcelRangeBase.Copy(ExcelRangeBase, ExcelRangeCopyOptionFlags?)
ExcelRangeBase.Copy(ExcelRangeBase, params ExcelRangeCopyOptionFlags[])
ExcelRangeBase.Copy(ExcelRangeBase)
ExcelRangeBase.CopyStyles(ExcelRangeBase)
ExcelRangeBase.CreateArrayFormula(string)
ExcelRangeBase.CreateHtmlExporter()
ExcelRangeBase.Current
ExcelRangeBase.DataValidation
ExcelRangeBase.Delete(eShiftTypeDelete)
ExcelRangeBase.Dispose()
ExcelRangeBase.EntireColumn
ExcelRangeBase.EntireRow
ExcelRangeBase.FillDateTime()
ExcelRangeBase.FillDateTime(Action<FillDateParams>)
ExcelRangeBase.FillDateTime(DateTime?, eDateTimeUnit, int)
ExcelRangeBase.FillList<T>(IEnumerable<T>, Action<FillListParams>)
ExcelRangeBase.FillList<T>(IEnumerable<T>)
ExcelRangeBase.FillNumber()
ExcelRangeBase.FillNumber(Action<FillNumberParams>)
ExcelRangeBase.FillNumber(double?, double)
ExcelRangeBase.Formula
ExcelRangeBase.FormulaR1C1
ExcelRangeBase.FormulaRange
ExcelRangeBase.FullAddress
ExcelRangeBase.FullAddressAbsolute
ExcelRangeBase.GetCellValue<T>()
ExcelRangeBase.GetCellValue<T>(int, int)
ExcelRangeBase.GetCellValue<T>(int)
ExcelRangeBase.GetEnumerator()
ExcelRangeBase.GetTable()
ExcelRangeBase.GetValue<T>()
ExcelRangeBase.Hyperlink
ExcelRangeBase.Insert(eShiftTypeInsert)
ExcelRangeBase.IsArrayFormula
ExcelRangeBase.IsRichText
ExcelRangeBase.IsTable
ExcelRangeBase.LoadFromArrays(IEnumerable<object[]>)
ExcelRangeBase.LoadFromArraysTransposed(IEnumerable<object[]>)
ExcelRangeBase.LoadFromCollection<T>(IEnumerable<T>, Action<LoadFromCollectionParams>)
ExcelRangeBase.LoadFromCollection<T>(IEnumerable<T>, bool, TableStyles?, BindingFlags, MemberInfo[])
ExcelRangeBase.LoadFromCollection<T>(IEnumerable<T>, bool, TableStyles?, bool, BindingFlags, MemberInfo[])
ExcelRangeBase.LoadFromCollection<T>(IEnumerable<T>, bool, TableStyles?, bool)
ExcelRangeBase.LoadFromCollection<T>(IEnumerable<T>, bool, TableStyles?)
ExcelRangeBase.LoadFromCollection<T>(IEnumerable<T>, bool)
ExcelRangeBase.LoadFromCollection<T>(IEnumerable<T>)
ExcelRangeBase.LoadFromDataReader(IDataReader, bool, bool)
ExcelRangeBase.LoadFromDataReader(IDataReader, bool, string, bool, TableStyles)
ExcelRangeBase.LoadFromDataReader(IDataReader, bool, string, TableStyles)
ExcelRangeBase.LoadFromDataReader(IDataReader, bool)
ExcelRangeBase.LoadFromDataReaderAsync(DbDataReader, bool, bool)
ExcelRangeBase.LoadFromDataReaderAsync(DbDataReader, bool, CancellationToken, bool)
ExcelRangeBase.LoadFromDataReaderAsync(DbDataReader, bool, CancellationToken)
ExcelRangeBase.LoadFromDataReaderAsync(DbDataReader, bool, string, bool, TableStyles, CancellationToken?)
ExcelRangeBase.LoadFromDataReaderAsync(DbDataReader, bool, string, TableStyles, CancellationToken?)
ExcelRangeBase.LoadFromDataReaderAsync(DbDataReader, bool)
ExcelRangeBase.LoadFromDataTable(DataTable, Action<LoadFromDataTableParams>)
ExcelRangeBase.LoadFromDataTable(DataTable, bool, TableStyles?, bool)
ExcelRangeBase.LoadFromDataTable(DataTable, bool, TableStyles?)
ExcelRangeBase.LoadFromDataTable(DataTable, bool)
ExcelRangeBase.LoadFromDataTable(DataTable)
ExcelRangeBase.LoadFromDictionaries(IEnumerable<dynamic>, Action<LoadFromDictionariesParams>)
ExcelRangeBase.LoadFromDictionaries(IEnumerable<dynamic>, bool, TableStyles?, IEnumerable<string>)
ExcelRangeBase.LoadFromDictionaries(IEnumerable<IDictionary<string, object>>, Action<LoadFromDictionariesParams>)
ExcelRangeBase.LoadFromDictionaries(IEnumerable<IDictionary<string, object>>, bool, TableStyles?, IEnumerable<string>)
ExcelRangeBase.LoadFromDictionaries(IEnumerable<IDictionary<string, object>>, bool, TableStyles?)
ExcelRangeBase.LoadFromDictionaries(IEnumerable<IDictionary<string, object>>, bool)
ExcelRangeBase.LoadFromDictionaries(IEnumerable<IDictionary<string, object>>)
ExcelRangeBase.LoadFromText(FileInfo, ExcelTextFormat, TableStyles?, bool)
ExcelRangeBase.LoadFromText(FileInfo, ExcelTextFormat)
ExcelRangeBase.LoadFromText(FileInfo, ExcelTextFormatFixedWidth)
ExcelRangeBase.LoadFromText(FileInfo)
ExcelRangeBase.LoadFromText(string, ExcelTextFormat, TableStyles?, bool)
ExcelRangeBase.LoadFromText(string, ExcelTextFormat)
ExcelRangeBase.LoadFromText(string, ExcelTextFormatFixedWidth)
ExcelRangeBase.LoadFromText(string)
ExcelRangeBase.LoadFromTextAsync(FileInfo, ExcelTextFormat, TableStyles, bool)
ExcelRangeBase.LoadFromTextAsync(FileInfo, ExcelTextFormat)
ExcelRangeBase.LoadFromTextAsync(FileInfo)
ExcelRangeBase.Merge
ExcelRangeBase.MoveNext()
ExcelRangeBase.Offset(int, int, int, int)
ExcelRangeBase.Offset(int, int)
ExcelRangeBase.Reset()
ExcelRangeBase.RichText
ExcelRangeBase.SaveToJson(Stream, Action<JsonRangeExportSettings>)
ExcelRangeBase.SaveToJson(Stream)
ExcelRangeBase.SaveToJsonAsync(Stream, Action<JsonRangeExportSettings>)
ExcelRangeBase.SaveToJsonAsync(Stream)
ExcelRangeBase.SaveToText(FileInfo, ExcelOutputTextFormat)
ExcelRangeBase.SaveToText(FileInfo, ExcelOutputTextFormatFixedWidth)
ExcelRangeBase.SaveToText(Stream, ExcelOutputTextFormat)
ExcelRangeBase.SaveToText(Stream, ExcelOutputTextFormatFixedWidth)
ExcelRangeBase.SaveToTextAsync(FileInfo, ExcelOutputTextFormat)
ExcelRangeBase.SaveToTextAsync(FileInfo, ExcelOutputTextFormatFixedWidth)
ExcelRangeBase.SaveToTextAsync(Stream, ExcelOutputTextFormat)
ExcelRangeBase.SaveToTextAsync(Stream, ExcelOutputTextFormatFixedWidth)
ExcelRangeBase.SetCellValue(int, int, object)
ExcelRangeBase.SetErrorValue(eErrorType)
ExcelRangeBase.SetHyperlink(ExcelHyperLink)
ExcelRangeBase.SetHyperlink(ExcelRange, string)
ExcelRangeBase.SetHyperlink(ExcelRange)
ExcelRangeBase.SetHyperlink(Uri)
ExcelRangeBase.Sort()
ExcelRangeBase.Sort(Action<RangeSortOptions>)
ExcelRangeBase.Sort(int, bool)
ExcelRangeBase.Sort(int[], bool[], CultureInfo, CompareOptions)
ExcelRangeBase.Sort(RangeSortOptions)
ExcelRangeBase.Style
ExcelRangeBase.StyleID
ExcelRangeBase.StyleName
ExcelRangeBase.Text
ExcelRangeBase.ThreadedComment
ExcelRangeBase.ToCollection<T>()
ExcelRangeBase.ToCollection<T>(Action<ToCollectionRangeOptions>)
ExcelRangeBase.ToCollection<T>(ToCollectionRangeOptions)
ExcelRangeBase.ToCollectionWithMappings<T>(Func<ToCollectionRow, T>, Action<ToCollectionRangeOptions>)
ExcelRangeBase.ToCollectionWithMappings<T>(Func<ToCollectionRow, T>, ToCollectionRangeOptions)
ExcelRangeBase.ToCollectionWithMappings<T>(Func<ToCollectionRow, T>)
ExcelRangeBase.ToDataTable()
ExcelRangeBase.ToDataTable(Action<ToDataTableOptions>, DataTable)
ExcelRangeBase.ToDataTable(Action<ToDataTableOptions>)
ExcelRangeBase.ToDataTable(DataTable)
ExcelRangeBase.ToDataTable(ToDataTableOptions, DataTable)
ExcelRangeBase.ToDataTable(ToDataTableOptions)
ExcelRangeBase.ToJson()
ExcelRangeBase.ToJson(Action<JsonRangeExportSettings>)
ExcelRangeBase.ToText()
ExcelRangeBase.ToText(ExcelOutputTextFormat)
ExcelRangeBase.ToText(ExcelOutputTextFormatFixedWidth)
ExcelRangeBase.ToTextAsync()
ExcelRangeBase.ToTextAsync(ExcelOutputTextFormat)
ExcelRangeBase.ToTextAsync(ExcelOutputTextFormatFixedWidth)
ExcelRangeBase.UseImplicitItersection
ExcelRangeBase.Value
ExcelRangeBase.Worksheet
object.Equals(object?, object?)
object.Equals(object?)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object?, object?)
object.ToString()

Extension Methods

CalculationExtension.Calculate(ExcelRangeBase, Action<ExcelCalculationOption>)
CalculationExtension.Calculate(ExcelRangeBase, ExcelCalculationOption)
CalculationExtension.Calculate(ExcelRangeBase)
RangeExtensions.SkipColumns(ExcelRangeBase, int)
RangeExtensions.SkipRows(ExcelRangeBase, int)
RangeExtensions.TakeColumns(ExcelRangeBase, int)
RangeExtensions.TakeColumnsBetween(ExcelRangeBase, int, int)
RangeExtensions.TakeRows(ExcelRangeBase, int)
RangeExtensions.TakeRowsBetween(ExcelRangeBase, int, int)
RangeExtensions.TakeSingleCell(ExcelRangeBase, int, int)
RangeExtensions.TakeSingleColumn(ExcelRangeBase, int)
RangeExtensions.TakeSingleRow(ExcelRangeBase, int)

Properties

this[string]

Access the range using an address

public ExcelRange this[string Address] { get; }

Property Value

ExcelRange

this[int, int]

Access a single cell

public ExcelRange this[int Row, int Col] { get; }

Property Value

ExcelRange

this[int, int, int, int]

Access a range of cells

public ExcelRange this[int FromRow, int FromCol, int ToRow, int ToCol] { get; }

Property Value

ExcelRange

Methods

SetFormula(string, bool)

Set the formula for the range.

public void SetFormula(string formula, bool asSharedFormula = true)

Parameters

formula string

The formula for the range.

asSharedFormula bool

If the formula should be created as a shared formula. If false each cell will be set individually. This can be useful if the formula returns a dynamic array result.