473,809 Members | 2,776 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Validate an Email Address

I want to validate an email address against our Exchange server. Anyone
have code or point me in the right direction?
John
Sep 4 '08 #1
3 1293
Maybe this will get you started?
http://www.codeproject.com/KB/aspnet..._from_NET.aspx

I'm assuming you mean more than just "is this a valid email address?"

"John Wright" <ri**********@h otmail.comwrote in message
news:OG******** ******@TK2MSFTN GP06.phx.gbl...
>I want to validate an email address against our Exchange server. Anyone
have code or point me in the right direction?
John

Sep 4 '08 #2
Maybe this will get you started?
http://www.codeproject.com/KB/aspnet..._from_NET.aspx

I'm assuming you mean more than just "is this a valid email address?"

"John Wright" <ri**********@h otmail.comwrote in message
news:OG******** ******@TK2MSFTN GP06.phx.gbl...
>I want to validate an email address against our Exchange server. Anyone
have code or point me in the right direction?
John

Sep 4 '08 #3
On Sep 4, 5:58 pm, "John Wright" <riley_wri...@h otmail.comwrote :
I want to validate an email address against our Exchange server. Anyone
have code or point me in the right direction?

John
If you're not meaning domain validation, but format validation of mail
address, you can use Regex pattern to check if it's a valid e-mail
address:

'-----Begin-------
Imports System.Text.Reg ularExpressions

Dim pattern As String
' I hope pattern is proper
pattern = "\w+([-+.]\w)*@\w+([-.]\w+)*\.\w+([-.]\w+)*"
If Regex.IsMatch(" mail_here", pattern) = True Then
MsgBox("Valid mail address!")
Else
MsgBox("Invalid mail address!")
End If
'-----End-------
Hope this helps,

Onur Güzel

Sep 5 '08 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

10
1971
by: michaaal | last post by:
I realize this is not solely an ASP question, but I thought you guys might know the answer and I couldn't find anywhere else to post this. If you have suggestions for this I am more than happy to post somewhere else. How can I, using ASP code, validate whether or not an email address is a real one? For example, if I have the email address called roy@rogers.net how can I determine if it is real?
12
5034
by: Dag Sunde | last post by:
My understanding of regular expressions is rudimentary, at best. I have this RegExp to to a very simple validation of an email-address, but it turns out that it refuses to accept mail-addresses with hypens in them. Can anybody please help me adjust it so it will accept addresses like dag-sunde@test-domain.net too?
5
7825
by: Dave | last post by:
Hello. Is there any method to validate if string contains valid IP address? I also need the method to valideta email address in string. Thank you.
3
4839
by: Wm. Scott Miller | last post by:
Hello all: I'd like some advice on the best way to validate and confirm an e-mail address entered during a registration process. What we are thinking of is something like the following: 1. User comes to our web site and validates themselves as a member of our database. 2. User creates a user name and password to be used to log in to our site. 3. User is required to enter a valid e-mail address to finalize
0
1723
by: comp.lang.php | last post by:
I wrote a method that should check if an email address is valid. In another method I've already checked to see if $_POST exists and is well-formed, so those checks are not necessary in this scope. However, "Step 4" bothers me, and I wonder if others are as bothered as I am. /** * Validate submitted email
23
2886
by: codefire | last post by:
Hi, I am trying to get a regexp to validate email addresses but can't get it quite right. The problem is I can't quite find the regexp to deal with ignoring the case james..kirk@fred.com, which is not valid. Here's my attempt, neither of my regexps work quite how I want: import os import re
26
25621
by: webrod | last post by:
Hi, I have some php pages with a lot of HTML code. I am looking for a HTML validator tool (like TIDY). TIDY is not good enough with PHP tags (it removes a lot of php code). Do you have any idea? Thanks you very much
1
4009
by: SkipNRun | last post by:
I am a novice when comes to JavaScript, AJAX. I am working on a form, which will allow users to update their contact information. In order to make the form flexible, I need to use pull down list. Depends on the pull down list selection, I use script.aculo.us to validate the user input before submit and pass the necessary data, such as contact type, contact information and ranking to a php program for updating. This form should allow multiple...
2
1945
by: Mick Walker | last post by:
Hi, I have a problem that I have been trying to figure for a couple of days, and am wondering if anyone out there would be so kind as to give me a solution. (Deadline time) I am trying to validate a form. Its quite a simple form, but I am a wee bit stuck. Baically it consists of 9 text input fields and a select element. All elements on the form, have to have a value in them (manditory), BUT 2 items (txtEmail, and txtDOB) have to match...
1
3145
by: saravanatmm | last post by:
I need javascript code for validate the email address. Email address field cannot allowed the capital letters, special characters except '@' symbol. But can allowed the small letters, numeric numbers. Now i use this script for validate the email address. But it allows the cpital letters otherwise its working correctly. SCRIPT FUNCTION ************************************************
0
9721
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9603
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10640
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10376
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10387
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10120
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9200
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6881
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
4332
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.