Para Dante - Eliminar filas en Lisbox, actualizar en excel

Estimado dante:

Muchas gracias por tu ayuda.

Necesito eliminar una registro en un list box el mismo que carga datos de una hoja excel.

Probé con un código pero no me funciona bien.

Te envío el archivo gracias

https://mega.co.nz/#!0M4EmBQZ!fwn_xumRAyKHmSz0K5-rFDlRZ39xYP8ahhWNa0n8J1Y 

1 respuesta

Respuesta
1

Para eliminar

Private Sub Eliminar_Click()
    If ListBox1.ListIndex = -1 Then Exit Sub
    Pregunta = MsgBox("Está seguro de eliminar el registro?", vbYesNo + vbQuestion, "EXCELeINFO")
    If Pregunta <> vbNo Then
        Rows(ListBox1.ListIndex + 2).Delete
    End If
    Call Actualizar_Click
End Sub

Añade tu respuesta

Haz clic para o

Más respuestas relacionadas