Home |
Search |
Today's Posts |
#4
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
This a UDF as given. Do you mean that you want to validate a single cell, a
column of cells? -- --- HTH Bob (there's no email, no snail mail, but somewhere should be gmail in my addy) "ljCharlie" wrote in message ... Bob Phillips Wrote: Add this VBA function '----------------------------------------------------------------- Public Function ValidEmail(Adress As String) As Boolean '----------------------------------------------------------------- Dim oRegEx As Object Set oRegEx = CreateObject("VBScript.RegExp") With oRegEx .Pattern = "^[\w-\.]{1,}\@([\da-zA-Z-]{1,}\.){1,}[\da-zA-Z-]{2,3}$" ' .Pattern = "^(\w+\.)*(\w+)@(\w+\.)+([a-zA-Z]{2,4})$" ValidEmail = .Test(Adress) End With Set oRegEx = Nothing End Function and use like ) How do I modify the code so that I can specify an email column? -- ljCharlie |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
how can i convert an email address to a web address | Excel Worksheet Functions | |||
can I copy a column of email addresses, paste into email address? | New Users to Excel | |||
Transfer Email addresses from spreadsheet to email address book | Excel Discussion (Misc queries) | |||
how do I sort email address, dedupes,check for errors in a docume. | Excel Discussion (Misc queries) | |||
Shut off email address from linking to email program? | Excel Worksheet Functions |