FarPoint.Win.Spread.FpSpread fSpread = new FarPoint.Win.Spread.FpSpread();
//设置 行数、列数
fSpread.ActiveSheet.Rows.Count = 90;
fSpread.ActiveSheet.Columns.Count = 10;
//获取行索引 列索引
int rowIndex = fSpread.ActiveSheet.ActiveRowIndex;
int colIndex = fSpread.ActiveSheet.ActiveColumnIndex;
//追加行 追加列
fSpread.ActiveSheet.Rows.Add(rowIndex,1);
fSpread.ActiveSheet.Columns.Add(colIndex,1);
//指定单元格获取焦点
fSpread.ActiveSheet.SetActiveCell(rowIndex, colIndex);
//隐藏列标题和序号
fSpread.ActiveSheet.ColumnHeader.Visible = false;
fSpread.ActiveSheet.RowHeaderVisible = false;
fSpread.ActiveSheet.RowHeaderColumnCount = 0;
fSpread.ActiveSheet.ColumnHeaderRowCount = 0;
//不显示网格线
//要领一、属性:
//GridShowHoriz = false;
//GridShowHoriz = false;
//要领二
fSpread.ActiveSheet.HorizontalGridLine = new FarPoint.Win.Spread.GridLine(FarPoint.Win.Spread.GridLineType.None);
fSpread.ActiveSheet.VerticalGridLine = new FarPoint.Win.Spread.GridLine(FarPoint.Win.Spread.GridLineType.None);
//不成编纂
fSpread.ActiveSheet.OperationMode = FarPoint.Win.Spread.OperationMode.ReadOnly;
/* 编纂模式
0 - Normal 默认的表单操纵都是可用的
1 - ReadOnly 仅仅读的
2 - RowMode 用户能够选择表单中的一行。而且能够通过双击来编纂该行任一单独的单元格
3 - SingleSelect 用户仅能选择一行,,而且不能编纂岂论什么的单元格
4 - MultiSelect 用户仅能选择多个持续行,可是不能编纂岂论什么一个单元格
5 - ExtendedSelect 用户仅能选择多个非持续行,可是不能编纂岂论什么一个单元格*/
//滚动栏(程度、垂直) 显示方法
// Always 依据情况超过显示范畴 显示滚动栏
// AsNeeded 一直显示
// Never 从不显示
fSpread.HorizontalScrollBarPolicy = FarPoint.Win.Spread.ScrollBarPolicy.AsNeeded;
fSpread.VerticalScrollBarPolicy = FarPoint.Win.Spread.ScrollBarPolicy.AsNeeded;