Tema: TextBox
Ver Mensaje Individual
  #5 (permalink)  
Antiguo 12/07/2006, 17:17
Avatar de Eärandir
Eärandir
 
Fecha de Ingreso: junio-2006
Ubicación: Torreón, México
Mensajes: 21
Antigüedad: 17 años, 11 meses
Puntos: 0
Cada text deberá tener un número de identificación en su propiedad Tag...

espero y esto te de una idea de como lo podrías hacer.

Código:
Private Sub verificar(Control As TextBox)
 If Control.SelLength <> 0 Then
  Label1.Caption = "selecciónando '" & Control.SelText & "' en: Text" & Control.Tag
 End If
End Sub


Private Sub Text1_KeyDown(KeyCode As Integer, Shift As Integer)
 If (KeyCode = 37 Or KeyCode = 38 Or KeyCode = 39 Or KeyCode = 40) And Shift = 1 Then
  verificar Text1
 End If
End Sub

Private Sub Text1_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
 If Button = 1 Then
  verificar Text1
 End If
End Sub

Private Sub Text2_KeyDown(KeyCode As Integer, Shift As Integer)
 If (KeyCode = 37 Or KeyCode = 38 Or KeyCode = 39 Or KeyCode = 40) And Shift = 1 Then
  verificar Text2
 End If
End Sub

Private Sub Text2_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
 If Button = 1 Then
  verificar Text2
 End If
End Sub
__________________
If you want to know the answers, then u gotta ask the questions