I am new to Regular Expression and I have this pattern below in my VBscript function for validating the email address.
regEx.Pattern ="^[\w-\.]{1,}\@([\da-zA-Z-]{1,}\.){1,}[\da-zA-Z-]{2,4}$"
1) Would someone please explain this pattern in words how this works? What is the dash (-) behind does? like w-, Z-
^[\w-\.]{1,}\@([\da-zA-Z-]{1,}\.){1,}[\da-zA-Z-]{2,4}$
2) Also, looks like it only return TRUE if the top-level domain is 2 to 3 characters (like .com, .edu). How can I change to unlimited top-level domain after the dot (.)? For examples: test1@domain1.career, test2@domain2.consulting
Thanks min advance,