0
I filled my Listview and applied a filter, so that the user can choose the values to be observed.
However, I need that the user can add information to the selected item and that these values are saved in the database source sheet in the same row and in an empty column specifies through the "ADD ACTION" button.
I’ve tried several ways and I don’t know if my code is also making sense...
Thank you all!
'''
Private Sub CommandButton1_Click()
Dim lineDp As Integer
Dim Dp As Worksheet
Dim Ultima_coluna As Long
Dim ColH As ColumnHeader
Dim Index As Long
Set Dp = Sheets("Details Pipeline")
'Number of Rows count
lineDp = Dp.Range("A100000").End(xlUp).Row
'Number of Colums count - Ctrl + Shift + End
Ultima_coluna = Dp.Cells(lineDp, Dp.Columns.Count).End(xlToLeft).Column
For i = 4 To Ultima_coluna
If Dp.Cells(3, i).Value <> "" Then
For j = 1 To ListView1.ListItems.Count
If ListView1.ListItems.Item(j).Checked Then
txt_id = ListView1.ListItems.Item(j)
Dp.Cells(j, i) = TextBox6.Text
End If
Next j
End If
Next i
Create a [mcve] with some sample data in a table.
– danieltakeshi