I am trying to populate a listbox using items in column P and I would like to ignore the blanks.
Private Sub UserForm_Initialize()
Dim strItem As String
Dim i As Long
For i = 1 To 500
If Cells(i, 16).Value = "" Then
Else
strItem = Selection.Value
Debug.Print strItem
lbxItems.AddItem strItem.Value
End If
End Sub
When I populate the listbox it all shows as blank. I expected it to be populated with the items in the column.