| {\rtf1\ansi\ansicpg1252\deff0\deflang1044{\fonttbl{\f0\fnil\fcharset0 MS Sans Serif;}} {\colortbl ;\red0\green0\blue255;} \viewkind4\uc1\pard\cf1\f0\fs17 Public Sub AltGridColor(msflex As Object, Colur As String) \cf0 \par Dim Icrow As Integer \par Dim Icol As Integer \par \tab If msflex.Rows > 2 Then \par \tab\tab For Icrow = 2 To msflex.Rows - 1 Step 2 \par \tab\tab\tab msflex.Row = Icrow \par \tab\tab\tab For Icol = 0 To msflex.Cols - 1 \par \tab\tab\tab\tab msflex.col = Icol msflex.CellBackColor = Colur \par \tab\tab\tab Next \par \tab\tab Next \par \tab End If \par \cf1 End Sub\cf0 \par \par 'OR \par \par \cf1 Public Sub AltGridColor(msflex As Object, Colur As String)\cf0 \par With msflex \par \tab .FillStyle = flexFillRepeat \par \tab .Redraw = False \par \tab For t = 1 To .Rows - 1 \par \tab\tab .Row = t .Col = 1 \par \tab\tab .RowSel = t \par \tab\tab .ColSel = .Cols - 1 \par \tab\tab If t Mod 2 = 0 Then \tab \par \tab\tab\tab .CellBackColor = Colur \par \tab\tab Else \par \tab\tab\tab .CellBackColor = WHITE \par \tab\tab End If \par \tab Next t \par \tab .Row = 1 \par \tab .Col = 1 \par \tab .RowSel = 1 \par \tab .ColSel = 1 \par \tab .FillStyle = flexFillSingle \par End With \par \cf1 End Sub\cf0 \par } |
Alternative Row colors for Flexi Grid |
India web developer web development India | India web development company India ecommerce web developer