Jump to content
Xtreme .Net Talk

Recommended Posts

Posted
Anyone has a code for validating email address (offline), I mean, to validate that the user type a good format (user@host.ext) in email txtbox? VB talking of course.
tHe pHrEaKy
Posted

Straight from MSDN:

 

Regex.IsMatch(address, @"^([\w-\.]+)@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.)|(([\w-]+\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\]?)$")

"Who is John Galt?"
Posted
Straight from MSDN:

 

Regex.IsMatch(address, @"^([\w-\.]+)@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.)|(([\w-]+\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\]?)$")

 

 

Well...thanks Ingis, but I don't know how to use what you gave me, because "Regex" is not a native function of VB, could you please teach me a little more about it? Sorry to bother, I'm kinda newbie with VB .NET, I'm using a txtbox, so, could you give me a piece of code using my txt_cariable.text, so I can use it? Thanks anyway for you concerning.

tHe pHrEaKy

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...