Monday, December 15, 2008

MERGE THE FLEX GRID ROWS IN VB 6.0

MERGE THE FLEX GRID ROWS IN VB 6.0


Dim i As Integer
With FX

.Rows = 2
.MergeCells = flexMergeFree
.MergeRow(0) = True
.MergeRow(1) = True
For i = 0 To 9
.MergeCol(i) = True
Next i

'*********************************************
.ROW = 0
.Col = 0
.Text = "Sl.No."
.ColWidth(0) = 350

.Col = 1
.Text = "Description"
.ColWidth(1) = 2925

.Col = 2
.Text = "Amount In"
.ColWidth(2) = 1050

.Col = 3
.Text = "Amount In"
.ColWidth(3) = 1050

.Col = 4
.Text = "Amount In"
.ColWidth(4) = 1050

.Col = 5
.Text = "Amount In"
.ColWidth(5) = 1050

.Col = 6
.Text = "Amount Out"
.ColWidth(6) = 1050

.Col = 7
.Text = "Amount Out"
.ColWidth(7) = 1050

.Col = 8
.Text = "Amount Out"
.ColWidth(8) = 1050

.Col = 9
.Text = "Amount Out"
.ColWidth(9) = 1050

'******************************************
.ROW = 1
.Col = 0
.Text = "Sl.No."
.ColWidth(0) = 350

.Col = 1
.Text = "Description"
.ColWidth(1) = 2925

.Col = 2
.Text = "Cash"
.ColWidth(2) = 1050

.Col = 3
.Text = "Credit Card"
.ColWidth(3) = 1050

.Col = 4
.Text = "Cheque"
.ColWidth(4) = 1050

.Col = 5
.Text = "Credit"
.ColWidth(5) = 1050

.Col = 6
.Text = "Cash"
.ColWidth(6) = 1050

.Col = 7
.Text = "Credit Card"
.ColWidth(7) = 1050

.Col = 8
.Text = "Cheque"
.ColWidth(8) = 1050

.Col = 9
.Text = "Credit"
.ColWidth(9) = 1050

For i = 0 To 9
.ROW = 0
.Col = i
.MergeCol(i) = True

.CellAlignment = 3
.CellFontBold = True

.ROW = 1
.Col = i
.CellAlignment = 3
.CellFontBold = TrueAdd Image
Next i

End With

No comments: