I'am using msflexgrid to display records from my table, after it display all, how can I set to display from the first record
thanks
cyrus
Printable View
I'am using msflexgrid to display records from my table, after it display all, how can I set to display from the first record
thanks
cyrus
Hint: Set the REDRAW to FALSE while you're drawing the table, and it will load quicker.
Code:Option Explicit
Private Sub Command1_Click()
Dim i As Integer
flx.Redraw = False
For i = 1 To flx.Rows - 1
If i Mod 2 = 0 Then
With flx
.FillStyle = flexFillRepeat
.Row = i
.RowSel = i
.Col = 1
.ColSel = .Cols - 1
.CellBackColor = vbRed
.CellForeColor = vbWhite
End With
End If
Next i
flx.Redraw = True
flx.Row = 1
End Sub
Private Sub Form_Load()
Dim i As Integer, j As Integer
With flx
For i = 1 To flx.Rows - 1
For j = 0 To .Cols - 1
.TextMatrix(i, j) = i & ", " & j
Next j
Next i
End With
End Sub