Namespace EasyXLS
Class ExcelHeader
System.Object
EasyXLS.ExcelHeader
public class ExcelHeader
extends System.Object
This class stores the header information extends text, position (left, center, or right), font name, font size, underline, strikethrough, superscript, subscript, page number, the number of pages, date and time, file name.
-
Constructor Summary
ConstructorsConstructorDescriptionDefines an instance of the header.ExcelHeader(System.String text, System.String position) Defines an instance of the header having the specified text and position.ExcelHeader(System.String text, System.String position, System.String fontName, int fontSize, bool isBold, bool isItalic) Defines an instance of the header having the specified text, position and font settings. -
Method Summary
Modifier and TypeMethodDescriptionClone()Creates and returns a copy of this object.System.StringReturns the header expression.System.StringReturns the position of the header.voidSets the bold style for the values that will follow the insertion.voidAppends the date to header expression.voidSets the double underline style for the values that will follow the insertion.voidAppends the enter character to header expression.voidAppends the file name to header expression.voidInsertFont(System.String fontType) Sets the font type for the values that will follow the font insertion.voidInsertFontSize(int fontSize) Sets the font size for the values that will follow the font size insertion.voidSets the italic style for the values that will follow the insertion.voidAppends the page number to header expression.voidAppends the total number of pages to header expression.voidSets the single underline style for the values that will follow the insertion.voidSets the strikethrough style for the values that will follow the insertion.voidSets the subscript style for the values that will follow the insertion.voidSets the superscript style for the values that will follow the insertion.voidAppends the tab character to header expression.voidAppends the date time to header expression.voidInsertValue(System.String value) Appends a string to header expression.voidRemoves the bold style for the values that will follow the insertion.voidRemoves the double underline style for the values that will follow the insertion.voidRemoves the italic style for the values that will follow the insertion.voidRemoves the single underline style for the values that will follow the insertion.voidRemoves the strikethrough style for the values that will follow the insertion.voidRemoves the subscript style for the values that will follow the insertion.voidRemoves the superscript style for the values that will follow the insertion.voidReset()Clears the header expression.voidsetHeaderString(System.String text) Sets the header expression.voidsetPosition(System.String position) Sets the position of the header.Methods inherited from class System.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
ExcelHeader
public ExcelHeader()Defines an instance of the header. -
ExcelHeader
public ExcelHeader(System.String text, System.String position) Defines an instance of the header having the specified text and position.- Parameters:
text- the text from the headerposition- the position of the header. Possible values are available inHeaderclass.
-
ExcelHeader
public ExcelHeader(System.String text, System.String position, System.String fontName, int fontSize, bool isBold, bool isItalic) Defines an instance of the header having the specified text, position and font settings.- Parameters:
text- the text from the headerposition- the position of the header. Possible values are available inHeaderclass.fontName- the font name of the headerfontSize- the font size of the headerisBold- the bold option of the headerisItalic- the italic option of header
-
-
Method Details
-
getHeaderString
public System.String getHeaderString()Returns the header expression.- Returns:
- the header expression
- See Also:
-
setHeaderString
public void setHeaderString(System.String text) Sets the header expression.- Parameters:
text- the header expression- See Also:
-
getPosition
public System.String getPosition()Returns the position of the header. Possible values are available inHeaderclass.- Returns:
- the position of the header
- See Also:
-
setPosition
public void setPosition(System.String position) Sets the position of the header. Possible values are available inHeaderclass.- Parameters:
position- the position of the header- See Also:
-
InsertValue
public void InsertValue(System.String value) Appends a string to header expression.- Parameters:
value- the value to be inserted
-
InsertFont
public void InsertFont(System.String fontType) Sets the font type for the values that will follow the font insertion.- Parameters:
fontType- the font type
-
InsertFontSize
public void InsertFontSize(int fontSize) Sets the font size for the values that will follow the font size insertion.- Parameters:
fontSize- the font size
-
InsertSingleUnderline
public void InsertSingleUnderline()Sets the single underline style for the values that will follow the insertion.- See Also:
-
RemoveSingleUnderline
public void RemoveSingleUnderline()Removes the single underline style for the values that will follow the insertion.- See Also:
-
InsertDoubleUnderline
public void InsertDoubleUnderline()Sets the double underline style for the values that will follow the insertion.- See Also:
-
RemoveDoubleUnderline
public void RemoveDoubleUnderline()Removes the double underline style for the values that will follow the insertion.- See Also:
-
InsertStrikethrough
public void InsertStrikethrough()Sets the strikethrough style for the values that will follow the insertion.- See Also:
-
RemoveStrikethrough
public void RemoveStrikethrough()Removes the strikethrough style for the values that will follow the insertion.- See Also:
-
InsertSuperscript
public void InsertSuperscript()Sets the superscript style for the values that will follow the insertion.- See Also:
-
RemoveSuperscript
public void RemoveSuperscript()Removes the superscript style for the values that will follow the insertion.- See Also:
-
InsertSubscript
public void InsertSubscript()Sets the subscript style for the values that will follow the insertion.- See Also:
-
RemoveSubscript
public void RemoveSubscript()Removes the subscript style for the values that will follow the insertion.- See Also:
-
InsertBold
public void InsertBold()Sets the bold style for the values that will follow the insertion.- See Also:
-
RemoveBold
public void RemoveBold()Removes the bold style for the values that will follow the insertion.- See Also:
-
InsertItalic
public void InsertItalic()Sets the italic style for the values that will follow the insertion.- See Also:
-
RemoveItalic
public void RemoveItalic()Removes the italic style for the values that will follow the insertion.- See Also:
-
InsertPage
public void InsertPage()Appends the page number to header expression. -
InsertPages
public void InsertPages()Appends the total number of pages to header expression. -
InsertDate
public void InsertDate()Appends the date to header expression. -
InsertTime
public void InsertTime()Appends the date time to header expression. -
InsertFile
public void InsertFile()Appends the file name to header expression. -
InsertTab
public void InsertTab()Appends the tab character to header expression. -
InsertEnter
public void InsertEnter()Appends the enter character to header expression. -
Reset
public void Reset()Clears the header expression. -
Clone
Creates and returns a copy of this object.- Returns:
- a clone of this instance.
-