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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Accessing Outlook Address Book

Status
Not open for further replies.

rohitpabby

Programmer
Aug 13, 2001
27
IN
HI There!

Can somebody tell me how I can get e-mail address, which I see in my MS Outlook in a drop-down, in an ASP page? I even don't know if this is possible or not.

Please help.

Thanks.

Warm Regards,
Rohit.
 
Goto File > Export as text file

then you could make a ASP file that reads the text file..


<%
Dim strEmails

Set objFS = CreateObject(&quot;Scripting.FileSystemObject&quot;)
Set objTX = objFS.OpenTextFile(Server.MapPath(&quot;emails.txt&quot;))

Response.Write objTX.ReadAll


%>
www.vzio.com
star.gif
if I helped. [wink]
 
After thinking about if for a little bit more, you could also make each one a mailto link if that was your plan..

I wrote this up, and it works like a charm..

<%
Dim strEmail, strEmail2

Set objFS = CreateObject(&quot;Scripting.FileSystemObject&quot;)
Set objTX = objFS.OpenTextFile(Server.MapPath(&quot;email.txt&quot;))

strEmail1 = objTX.ReadAll

strEmail = Split(strEmail2, vbCrlf)

For each Email in strEmail

If InStr(Email, &quot;@&quot;) > 0 AND InStr(Email, &quot;.&quot;) then

Response.Write &quot;<a href=mailto:&quot; & Email & &quot;>&quot; & Email & &quot;</a><br>&quot;

End if

Next


%>
www.vzio.com
star.gif
if I helped. [wink]
 
Im addicted to the computer... eh I keep playing with this email thing.. I made it so now if you check Name and Email it will display it in this format..

Persons Name
email@somewhere.com

Persons Name
email@somewhere.com

..


<%
Dim strEmail, strEmail1

Set objFS = CreateObject(&quot;Scripting.FileSystemObject&quot;)
Set objTX = objFS.OpenTextFile(Server.MapPath(&quot;email.txt&quot;))

strEmail = objTX.ReadAll

strEmail = Split(strEmail, vbCrlf)

For each Email in strEmail



If InStr(Email, &quot;@&quot;) > 0 AND InStr(Email, &quot;.&quot;) then


strEmailSplit = Split(Email, &quot;,&quot;)


Response.Write &quot;<b>&quot; & strEmailSplit(0) & &quot;</b><br>&quot; & &quot;<a href=mailto:&quot; & strEmailSplit(1) & &quot;>&quot; & strEmailSplit(1) & &quot;</a><br><br>&quot;


End if

Next


%>

Let me know how these work out for you..


www.vzio.com
star.gif
if I helped. [wink]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top