Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Checking e-mail addresses against each other in array

Status
Not open for further replies.

Atchett

Programmer
Dec 7, 2000
35
0
0
Hi All,

I am pretty new to ASP and have a bit of a problem.
I have a list of e-mail addresses that have been collected with a form on a web page. I would like to be able to check them against each other in the simplest way possible. I have looked into using an array but I am unsure of how to do this. If any of them are the same then I would like to be able to send the user back to the page they were on to re-enter the email addresses. Bearing in mind that some of the addresses may be blank does anyone have an idea of how I can achieve this.

This is where I got to with the array..

dim MailAddr(5)
MailAddr(0)="var_EmailAddress"
MailAddr(1)="var_Friend1Name"
MailAddr(2)="var_Friend2Name"
MailAddr(3)="var_Friend3Name"
MailAddr(4)="var_Friend4Name"

and this is what I would like to happen if the e-mail addresses are the same. marker = 2 sends the user to a part of the page which tells them that they are going to be redirected to the previous page.

if "var_EmailAddress" = "var_Friend1Name" then
marker = 2
end if

Any help would be much appreciated.
 
Well can't see anything wrong with that. Assuming that you are using the value method
ie if MailAddr(0).value = MailAddr(1).value then
...
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top