Results 1 to 3 of 3
  1. #1
    Accession is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Sep 2011
    Posts
    7

    Why is this email validation expression form Microsoft not working?

    Good day everyone,

    I copied this expression/Validation Rule from Microsoft Website and placed it in the field (column) validation text rule. According to Microsoft, it is suppose to validate for the following: .com, .net, or .org e-mail addresses.

    The problem is, when I first enter an invalid e-mail to check the validation rule, validation message fires up as expected. However, when I enter a valid e-mail address I still get the error message telling me to enter valid e-mail.

    No matter what I do I keep getting the error message.



    Here is the expression:
    Code:
    LIKE "[A-Z]*@[A-Z].com" OR "[A-Z]*@[A-Z].net" OR "[A-Z]*@[A-Z].org"

    This is really killing me.

    Thanks everyone.

    Accession

  2. #2
    ajetrumpet is offline VIP
    Windows Vista Access 2007
    Join Date
    Mar 2010
    Location
    N/A
    Posts
    2,694
    I wouldn't doubt that MS is wrong. Allen Browne has a good one here:

    http://allenbrowne.com/ValidationRule.html

    not sure if that'll work for you though.

  3. #3
    Accession is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Sep 2011
    Posts
    7
    Quote Originally Posted by ajetrumpet View Post
    I wouldn't doubt that MS is wrong. Allen Browne has a good one here:

    http://allenbrowne.com/ValidationRule.html

    not sure if that'll work for you though.

    Thanks a lot for responding, I did see the Allen Brown expression but I noticed it stopped short for looking for a dot com or dot something in an email address.

    So I modified it like this: It will not allow emails with out dot something. It is not the best because the user can enter say: .c or .something with one letter, rather than com or net.

    But I am just burnt out and will leave it this way.

    Anyway this is what I have:
    Code:
    Is Null Or ((Like "*?@?*.?*") Or ((Like "*?.com?*") Or ((Like "*?com?*") And (Not Like "*[ ,;]*"))))
    Thanks again.

    Accession

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 5
    Last Post: 05-04-2019, 09:02 PM
  2. Replies: 9
    Last Post: 11-22-2011, 05:23 PM
  3. Replies: 1
    Last Post: 09-13-2011, 01:52 PM
  4. Auto email not working
    By edzigns in forum Programming
    Replies: 1
    Last Post: 04-29-2011, 12:41 PM
  5. Replies: 1
    Last Post: 09-09-2009, 04:42 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums