MESCIUS SPREAD for Windows Forms 17.0J
AltRowCount プロパティ (ISheetStyleModel)

モデル内の交互行のスタイルの数を取得または設定します。
構文
'Declaration
 
Property AltRowCount As Integer
int AltRowCount {get; set;}

プロパティ値

交互行の数を表す Integer
次のサンプルコードは、交互行の数を設定し、背景色を変更します。
FarPoint.Win.Spread.Model.ISheetStyleModel ssm;
FarPoint.Win.Spread.Model.ISheetStyleModel ssm1;
FarPoint.Win.Spread.NamedStyle ns = new FarPoint.Win.Spread.NamedStyle("StyleData");
FarPoint.Win.Spread.NamedStyle ns1 = new FarPoint.Win.Spread.NamedStyle("StyleHeaders");
ssm = (FarPoint.Win.Spread.Model.ISheetStyleModel)fpSpread1.ActiveSheet.Models.Style;
ssm1 = (FarPoint.Win.Spread.Model.ISheetStyleModel)fpSpread1.ActiveSheet.Models.ColumnHeaderStyle;
ns.BackColor = Color.LightBlue;
ns1.BackColor = Color.Yellow;
fpSpread1.NamedStyles.AddRange(new object[] {ns, ns1});
ssm.AltRowCount = 2;
ssm.SetDirectAltRowInfo(0, ns);
ssm1.SetDirectAltRowInfo(0, ns1);
Dim ssm As FarPoint.Win.Spread.Model.ISheetStyleModel
Dim ssm1 As FarPoint.Win.Spread.Model.ISheetStyleModel
Dim ns As New FarPoint.Win.Spread.NamedStyle("StyleData")
Dim ns1 As New FarPoint.Win.Spread.NamedStyle("StyleHeaders")
ssm = FpSpread1.ActiveSheet.Models.Style
ssm1 = FpSpread1.ActiveSheet.Models.ColumnHeaderStyle
ns.BackColor = Color.LightBlue
ns1.BackColor = Color.Yellow
FpSpread1.NamedStyles.AddRange(New Object() {ns, ns1})
ssm.AltRowCount = 2
ssm.SetDirectAltRowInfo(0, ns)
ssm1.SetDirectAltRowInfo(0, ns1)
参照

ISheetStyleModel インタフェース
ISheetStyleModel メンバ

 

 


© MESCIUS inc. All rights reserved.