C# Class Smrf.NodeXL.ExcelTemplate.TableColumnAdder

Adds columns to an Excel table (ListObject), and finds the columns that were added.
Use AddColumnPair to add a pair of columns to a table. Use GetColumnPairNames to get a collection of all the columns pairs that were added.
Inheritance: Object
显示文件 Open project: 2014-sed-team3/term-project Class Usage Examples

Public Methods

Method Description
AddColumnPair ( Microsoft workbook, String worksheetName, String tableName, String column1NameBase, Double column1WidthChars, String column2NameBase, Double column2WidthChars ) : void
GetColumnPairNames ( ListObject table, String column1NameBase, String column2NameBase ) : String>>.ICollection
TableColumnAdder ( ) : System

Initializes a new instance of the TableColumnAdder class.

Protected Methods

Method Description
GetColumnNameRegex ( String sColumnNameBase ) : Regex
GetMaximumAppendedNumber ( ListObject oTable, String sColumnNameBase ) : Int32

Private Methods

Method Description
AssertValid ( ) : void

Method Details

AddColumnPair() public method

public AddColumnPair ( Microsoft workbook, String worksheetName, String tableName, String column1NameBase, Double column1WidthChars, String column2NameBase, Double column2WidthChars ) : void
workbook Microsoft
worksheetName String
tableName String
column1NameBase String
column1WidthChars Double
column2NameBase String
column2WidthChars Double
return void

GetColumnNameRegex() protected method

protected GetColumnNameRegex ( String sColumnNameBase ) : Regex
sColumnNameBase String
return System.Text.RegularExpressions.Regex

GetColumnPairNames() public method

public GetColumnPairNames ( ListObject table, String column1NameBase, String column2NameBase ) : String>>.ICollection
table ListObject
column1NameBase String
column2NameBase String
return String>>.ICollection

GetMaximumAppendedNumber() protected method

protected GetMaximumAppendedNumber ( ListObject oTable, String sColumnNameBase ) : Int32
oTable ListObject
sColumnNameBase String
return System.Int32

TableColumnAdder() public method

Initializes a new instance of the TableColumnAdder class.
public TableColumnAdder ( ) : System
return System