Está en la página 1de 2

Casilla de verificación Chk03, No tiene experiencia

Casilla de verificación Chk04, Ha viajado al extranjero

Comando CmdActivar, Activar

Comando CmdClear, Limpiar

Comando CmdFin, Salir

Cuadro de texto TxtLista, Propiedad: Mulitiline: True

El código completo se muestra en las siguientes líneas

Private Sub CmdActivar_Click()

If Opt00 Then

TxtLista.Text = "Mujer con "

Else

TxtLista.Text = "Hombre con "

End If

If Chk00 Then TxtLista.Text = TxtLista.Text + Chk00.Caption + Chr(13)

If Chk01 Then TxtLista.Text = TxtLista.Text + Chk01.Caption + Chr(13)

If Chk02 Then TxtLista.Text = TxtLista.Text + Chk02.Caption + Chr(13)

If Chk03 Then TxtLista.Text = TxtLista.Text + Chk03.Caption + Chr(13)

If Chk04 Then TxtLista.Text = TxtLista.Text + Chk04.Caption + Chr(13)

End Sub

Private Sub CmdClear_Click()

Chk00.Value = False

Chk01.Value = False

Chk02.Value = False

Alfredo Rico – RicoSoft - 2011 145


Chk03.Value = False

Chk04.Value = False

Opt00.Value = False

Opt01.Value = False

TxtLista.Text = ""

End Sub

Private Sub CmdSalir_Click()

End

End Sub

Nota:

El libro Paneles.xlsm contiene los últimos formularios de estos ejemplos.

Control de Barra de desplazamiento y Control Botón de número

Estos controles permiten asignar un valor a una variable o a otro objeto, para un
valor del desplazamiento que se haya realizado en dicho botón.

Ejemplo 17

Este ejemplo permite seleccionar un valor para el peso y otro para la edad, los cuales
se visualizan en sus respectivos cuadros de texto.

La siguiente imagen muestra dicho formulario

Alfredo Rico – RicoSoft - 2011 146

También podría gustarte