Error al compilar: next sin for
Tengo este código
Private Sub validar()
Dim h, i
Set h = Sheets("Programación")
For i = 2 To h.Range("A" & Rows.Count).End(xlUp).Row
Do While Cells(i, "C") <> Cmbxnombre.Text And Cells(i, "I") <> CDate(Txbxfecini)
i = i + 1
'MsgBox "1"
Loop
If Cells(i, "C") = Cmbxnombre.Text And Cells(i, "I") = CDate(Txbxfecini) Then
MsgBox "La persona " & Cells(i, "C") & " ya está programada para la fecha " & Cells(i, "I")
End
Next
End SubCuando lo ejecuto me sale error de compilación: Next sin For.
2 respuestas
Respuesta de Aneudys Martinez
1
Respuesta de manuel seijas

me puede apoyar hacer un programa donde puede ver el nombre y apellido del usuario y me salga un resultado - jasmin martinez