Ver Mensaje Individual
  #3 (permalink)  
Antiguo 18/11/2004, 17:24
miguel_20042004
 
Fecha de Ingreso: agosto-2004
Mensajes: 23
Antigüedad: 19 años, 7 meses
Puntos: 0
asi tambien puede ser.....este ejemplo valida la entrada correcta de un email


Imports System.Text.RegularExpressions


Private Sub Text_User_LostFocus(ByVal sender As Object, ByVal e As System.EventArgs) Handles Text_User.LostFocus
Dim r As Regex
Dim m As Match
r = New Regex("^([\w-\.]+)@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.)|(([\w-]+\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\]?)$")
Dim mc As MatchCollection = r.Matches(Text_User.Text)
If mc.Count <> 1 Then 'Valor ingresado correcto con respecto a expresion regular
errorlogin.Visible = True
Else
errorlogin.Visible = False
End If
End Sub

tambien (no lo he visto aun ) pero hay un componente "ErrorProvider " q podrias revisar tambien...
este link te puede servir de algo....

http://www.microsoft.com/spanish/msd...ms03162004.asp


espero te sirva...
saludos