Gets the index of the column specified by name.
Syntax
Parameters
- columnName
- Column name
Example
This example returns the index of the specified column.
C# | Copy Code |
---|
FarPoint.Win.Spread.Model.DefaultSheetDataModel dm;
dm = fpSpread1.ActiveSheet.Models.Data;
int i = dm.GetColumnIndex("EmployeeID");
fpSpread1.ActiveSheet.Columns[i].ForeColor = Color.Red;
|
Visual Basic | Copy Code |
---|
Dim dm As FarPoint.Win.Spread.Model.DefaultSheetDataModel
dm = FpSpread1.ActiveSheet.Models.Data
Dim i As Integer = dm.GetColumnIndex("EmployeeID")
FpSpread1.ActiveSheet.Columns(i).ForeColor = Color.Red
|
Requirements
Target Platforms: Windows 2000 Professional (SP4), Windows 2000 Server, Windows 2003 Server (SP1), Windows 2008, Windows XP (SP2), Windows Vista, Windows 7, Windows 8
See Also