Te anexo el código actualizado
Sub filtrar()
'Por.Dante Amor
u = h2.Range("E" & Rows.Count).End(xlUp).Row
h2.Range("E2:F" & u + 2).Clear
ListBox1.RowSource = ""
h2.Range("D2") = TextBox1 & "*"
h2.Range("E2") = ComboBox1
h2.Range("F2") = "SI"
u = h2.Range("A" & Rows.Count).End(xlUp).Row
h2.Range("A1:C" & u).AdvancedFilter Action:=xlFilterCopy, _
CriteriaRange:=h2.Range("D1:F2"), CopyToRange:=h2.Range("G1:I1"), Unique:=False
u = h2.Range("G" & Rows.Count).End(xlUp).Row
If u > 1 Then
ListBox1.RowSource = h2.Name & "!G2:H" & u
End If
End Sub
'
Private Sub UserForm_Activate()
'Por.Dante Amor
'Cargar
Set h2 = Sheets("NOMBRES")
h2.Range("A2:B" & h2.Range("A" & Rows.Count).End(xlUp).Row + 2).Clear
j = 2
For Each h In Sheets
una = True
Select Case UCase(h.Name)
Case Is = "PLANTILLA", "BUSCAR", "NOMBRES"
Case Else
'carga hojas
ComboBox1.AddItem h.Name
'carga nombres
For i = 4 To h.Range("A" & Rows.Count).End(xlUp).Row
If una Then
pri = h.Cells(i, "A")
una = False
Else
If h.Cells(i, "A") = pri Then Exit For
End If
If h.Cells(i, "A") <> "" Then
h2.Cells(j, "A") = h.Cells(i, "A")
h2.Cells(j, "B") = h.Name
j = j + 1
End If
Next
End Select
Next
u = h2.Range("A" & Rows.Count).End(xlUp).Row
For i = 2 To u
'ListBox1.RowSource = h2.Name & "!A2:B" & u
If h2.Cells(i, "C") = "SI" Then
ListBox1.AddItem h2.Cells(i, "A")
End If
Next
'
'Carga tipos
'"vacaciones, permiso o pex"
ComboBox2.AddItem "Vacaciones"
ComboBox2.List(0, 1) = "V"
ComboBox2.AddItem "Permiso"
ComboBox2.List(1, 1) = "AP"
ComboBox2.AddItem "Pex"
ComboBox2.List(2, 1) = "PEX"
End Sub
sal u dos