Class ExcelTextFormatFixedWidthBase¶
Namespace: OfficeOpenXml
Assembly: EPPlus.dll
Describes how to import a fixed width text file.
Inheritance¶
object ← ExcelTextFileFormat ← ExcelTextFormatFixedWidthBase
Derived¶
ExcelOutputTextFormatFixedWidth
ExcelTextFormatFixedWidth
Inherited Members¶
ExcelTextFileFormat.Culture
ExcelTextFileFormat.Encoding
ExcelTextFileFormat.EOL
ExcelTextFileFormat.FirstRowIsHeader
ExcelTextFileFormat.ShouldUseRow
ExcelTextFileFormat.SkipLinesBeginning
ExcelTextFileFormat.SkipLinesEnd
ExcelTextFileFormat.TableStyle
ExcelTextFileFormat.Transpose
object.Equals(object?, object?)
object.Equals(object?)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object?, object?)
object.ToString()
Constructors¶
ExcelTextFormatFixedWidthBase()¶
Properties¶
Columns¶
The collection of column formats.
Property Value¶
EPPlusReadOnlyList<ExcelTextFormatColumn>
FormatErrorStrategy¶
The strategy to use when writing fixed width text files.
Property Value¶
LineLength¶
The length of the line to read. If set to widths, LineLength is sum of all columnLengths. If set to positions, LineLength is set to the value of the last index of columnLengths
Property Value¶
PaddingCharacter¶
Padding character for Text Can be set to null to skip trimming padding characters when reading
Property Value¶
PaddingCharacterNumeric¶
Padding character for numbers.
Property Value¶
char?
Methods¶
ClearColumnFormats()¶
Clear the collection of column formats.
SetColumnDataTypes(params eDataTypes[])¶
Set the data types for each column.
Parameters¶
dataTypes eDataTypes[]
SetColumnLengths(params int[])¶
Set the column length properties of fixed width text. For reading to end of line, set last index to 0 or a negative number.
Parameters¶
lengths int[]
SetColumnPaddingAlignmentType(params PaddingAlignmentType[])¶
Set the padding type for each column.
Parameters¶
paddingTypes PaddingAlignmentType[]
SetColumnPositions(int, params int[])¶
Set the column start positions of fixed width text.
Parameters¶
lineLength int
The Length of a line. Set to 0 or negative to read until end of line.
positions int[]
The positions where each column starts. This array requires atleast one element.
SetColumnsNames(params string[])¶
Set flag for each column to be used.
Parameters¶
Names string[]
SetUseColumns(params bool[])¶
Set flag for each column to be used.
Parameters¶
UseColumns bool[]