Hello, sorry for this late reply.
Am i mistaken or is the code that you send me for a combo box and not for a Check box?
below is how I am filling the data into the iGrid, however column 6,8,10,17 and 18 now display a True or False value which I would like to have displayed as a check box .
Then I have column 3,5 and 7 as a Combobox which I would like to populate with a named Range.
The code below fills it up without any issues and when I change the data the sheets is updated as well, so that is not the issue.
It is only the check boxes that I can't seem to get going and I can't get the Combobox filled with the named range.
Private Sub UserForm_Initialize()
Dim i As Integer
Dim LastRow As Long
LastRow = ShIngredientsData.Cells(ShIngredientsData.Rows.Count, "A").End(xlUp).Row - 1
iGrid1.ColCount = 28
iGrid1.RowCount = LastRow
For i = 1 To LastRow
iGrid1.CellValue(i, 1) = ShIngredientsData.Range("A" & i + 1).Value
iGrid1.CellValue(i, 2) = ShIngredientsData.Range("B" & i + 1).Value
iGrid1.CellValue(i, 3) = ShIngredientsData.Range("C" & i + 1).Value
iGrid1.CellValue(i, 4) = ShIngredientsData.Range("D" & i + 1).Value
iGrid1.CellValue(i, 5) = ShIngredientsData.Range("E" & i + 1).Value
iGrid1.CellValue(i, 6) = ShIngredientsData.Range("F" & i + 1).Value
iGrid1.CellValue(i, 7) = ShIngredientsData.Range("G" & i + 1).Value
iGrid1.CellValue(i, 8 ) = ShIngredientsData.Range("H" & i + 1).Value
iGrid1.CellValue(i, 9) = ShIngredientsData.Range("I" & i + 1).Value
iGrid1.CellValue(i, 10) = ShIngredientsData.Range("J" & i + 1).Value
iGrid1.CellValue(i, 11) = ShIngredientsData.Range("K" & i + 1).Value
iGrid1.CellValue(i, 12) = ShIngredientsData.Range("L" & i + 1).Value
iGrid1.CellValue(i, 13) = ShIngredientsData.Range("M" & i + 1).Value
iGrid1.CellValue(i, 14) = ShIngredientsData.Range("N" & i + 1).Value
iGrid1.CellValue(i, 15) = ShIngredientsData.Range("O" & i + 1).Value
iGrid1.CellValue(i, 16) = ShIngredientsData.Range("P" & i + 1).Value
iGrid1.CellValue(i, 17) = ShIngredientsData.Range("Q" & i + 1).Value
iGrid1.CellValue(i, 18) = ShIngredientsData.Range("R" & i + 1).Value
iGrid1.CellValue(i, 19) = ShIngredientsData.Range("S" & i + 1).Value
iGrid1.CellValue(i, 20) = ShIngredientsData.Range("T" & i + 1).Value
iGrid1.CellValue(i, 21) = ShIngredientsData.Range("U" & i + 1).Value
iGrid1.CellValue(i, 22) = ShIngredientsData.Range("V" & i + 1).Value
iGrid1.CellValue(i, 23) = ShIngredientsData.Range("W" & i + 1).Value
iGrid1.CellValue(i, 24) = ShIngredientsData.Range("X" & i + 1).Value
iGrid1.CellValue(i, 25) = ShIngredientsData.Range("Y" & i + 1).Value
iGrid1.CellValue(i, 26) = ShIngredientsData.Range("Z" & i + 1).Value
iGrid1.CellValue(i, 27) = ShIngredientsData.Range("AA" & i + 1).Value
Next i
End Sub
Edited by user
2020-05-21T07:19:04Z
|
Reason: Not specified