投稿日 | : 2003/04/25(Fri) 17:26 |
投稿者 | : brooklyn |
Eメール | : |
URL | : |
タイトル | : MSFlexGridに関しての質問 |
MSFlexGridに関しての質問です。
よろしくお願いします。
フォーム上の3120,360,3615,3855に3行200列の
MDFlexGridを置きたいんですが、以下のコードだと
エラーが出てしまいます。
申し訳ありませんがお教えください。
よろしくお願いします。
Option Explicit
Private CurrentRowNo As Integer
Private Sub Form_Load()
Dim lngCountI As Long
'MSFlexGrid の初期設定
With MSFlexGrid1
.Move 3120, 360, 3615, 3855
.Rows = 200
.Cols = 3
.FixedRows = 1
.FixedCols = 1
.Row = 0
.ColWidth(0) = 430
.ColWidth(1) = 1800
.ColWidth(2) = 550
For lngCountI = 1 To 3
.ColWidth(lngCountI) = 1000 ←ココなんです。
Next lngCountI
.RowHeight(0) = 350 '行の高さ
'該当セルを 中寄/中寄 表示
.CellAlignment = flexAlignCenterCenter
.Col = 1: .Text = "氏 名"
.CellAlignment = flexAlignCenterCenter
.Col = 2: .Text = "性 別"
.CellAlignment = flexAlignCenterCenter
.Col = 0
For lngCountI = 1 To .Rows - 1
.RowHeight(lngCountI) = 350 '行の高さ
.Row = lngCountI
.Text = lngCountI '行番号を表示
Next lngCountI
.Col = 1: .Row = 1
.FocusRect = flexFocusNone
.HighLight = flexHighlightAlways
End With
txtSimei.Text = ""
End Sub
Private Sub Form_Activate()
txtSimei.SetFocus
End Sub