Saltar al contenido
View in the app

A better way to browse. Learn more.

Ayuda Excel

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Definir una acción para múltiples textboxes

publicado

Estimados,

Necesito una manera rápida de definir una acción para varios textbox. Por ejemplo, me gustaría definir la misma acción al hacer click para los textbox 1-5, otra para 6-10 y otra para 11-15. La idea es que voy a tener un contador que me diga para cuales textboxes voy a hacer la accion A, B o C.

Saludos

Textbox.zip

Featured Replies

publicado

Aquí te dejo tu archivo con lo que creo que quieres, cosa que no queda demasiado clara porqué los TextBox carecen de evento Click. Ejecuta el formulario y escribe en cualquiera de los textbox.

Copia de Textbox.xls

publicado

Buenas a los 2.......

Quizás, querido Macro, se estaba refiriendo al evento Enter......que en el fondo se dispara al hacer "click"....jejeje

Un saludo,

Tese

publicado
  • Autor

No sabía que no había evento Click en textbox... como ven soy muy nuevo en esto de visual basic. Ahora voy a ver la posiblidad de usar Labels, pero tengo la misma duda. ¿puedo definir de una manera eficiente las siguientes acciones?


Private Sub TextBox1_Enter()
MsgBox "Acción 1"
End Sub
Private Sub TextBox2_Enter()
MsgBox "Acción 1"
End Sub
Private Sub TextBox3_Enter()
MsgBox "Acción 1"
End Sub
Private Sub TextBox4_Enter()
MsgBox "Acción 1"
End Sub
Private Sub TextBox5_Enter()
MsgBox "Acción 1"
End Sub
Private Sub TextBox6_Enter()
MsgBox "Acción 2"
End Sub
Private Sub TextBox7_Enter()
MsgBox "Acción 2"
End Sub
Private Sub TextBox8_Enter()
MsgBox "Acción 2"
End Sub
Private Sub TextBox9_Enter()
MsgBox "Acción 2"
End Sub
Private Sub TextBox10_Enter()
MsgBox "Acción 2"
End Sub
Private Sub TextBox11_Enter()
MsgBox "Acción 3"
End Sub
Private Sub TextBox12_Enter()
MsgBox "Acción 3"
End Sub
Private Sub TextBox13_Enter()
MsgBox "Acción 3"
End Sub
Private Sub TextBox14_Enter()
MsgBox "Acción 3"
End Sub
Private Sub TextBox15_Enter()
MsgBox "Acción 3"
End Sub
[/CODE]

Textbox2.zip

Archivado

Este tema está ahora archivado y está cerrado a más respuestas.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.