473,803 Members | 3,410 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

ASPPop3 (Server Objects) fails to return email details

Can anyone tell me why this code doesn't work? The original came from
an example in this group, but was modified slightly when the original
failed to return message details.

I am able to connect to the server and see the number of messages on
the server, but message details (sender, subject, body, etc.) are not
returned.

_______________
Dim Mailer
Set Mailer = Server.CreateOb ject("POP3svg.M ailer")
Mailer.RemoteHo st = "mail.xxxx. com"
Mailer.UserName = "te**@xxxx. com"
Mailer.Password = "pwd"
Mailer.OpenPop3
Dim iMessages
iMessages = Mailer.MessageC ount
Response.Write "There are " & iMessages & " messages on the
server.<p>"

Dim iLoop

Response.Write "<table border=1 align=center cellspacing=1>"
Response.Write
"<tr><th>&nbsp; </th><th>Subject</th><th>From</th></tr>"

For iLoop = 1 to iMessages
'If Mailer.Retrieve (iLoop) then
Mailer.Retrieve iloop

Response.Write "<tr>"
Response.Write "<td><a href=""readMess age.asp?ID=" & iLoop &
""">Read</a></td>"
Response.Write "<td>" & Mailer.Subject & "</td>"
Response.Write "<td>" & Mailer.FromName & " (<a href=""mailto:" ""
& Mailer.FromAddr ess & """>" & Mailer.FromAddr ess & "</a>)</td>"
Response.Write "</tr>"
'End If

Next

Response.Write "</table>"

Mailer.ClosePop 3

Jul 31 '05 #1
6 2201
Rich_C wrote:
Can anyone tell me why this code doesn't work? The original
came from an example in this group, but was modified
slightly when the original failed to return message details.

I am able to connect to the server and see the number of
messages on the server, but message details (sender,
subject, body, etc.) are not returned.
POP3svg.Mailer is not part of ASP, so if the problem is with that interface,
this is probably the wrong forum.

Beyond that, I have an observation and a question. First, the observation.
It appears you are breaking your HTML in this line:
Response.Write "<td>" & Mailer.FromName &_
" (<a href=""mailto:" "" & Mailer.FromAddr ess &_
""">" & Mailer.FromAddr ess & "</a>)</td>"


The resulting ouput will be something like this:

<td>Rich_C (<a href="mailto:"R i****@xxx.com">
FromAddress</a>)</td>

In other words, you have an extra quote between the mailto: and the address.

My question is: Are you certain the message details are not returned? Have
you looked at the HTML generated by this script, or merely at the browser's
interpretation of your broken HTML?

--
Dave Anderson

Unsolicited commercial email will be read at a cost of $500 per message. Use
of this email address implies consent to these terms. Please do not contact
me directly or ask me to contact you directly for assistance. If your
question is worth asking, it's worth posting.
Jul 31 '05 #2
Thanks Dave -
Even if I only try to display one part of the email (Subject, FromName,
etc.) nothing is returned.

Jul 31 '05 #3
Did you look at the HTML, as Dave suggested? Or, are you assuming nothing
was returned because you don't see it on the page?

Bob Lehmann

"Rich_C" <Ri********@aol .com> wrote in message
news:11******** **************@ o13g2000cwo.goo glegroups.com.. .
Thanks Dave -
Even if I only try to display one part of the email (Subject, FromName,
etc.) nothing is returned.

Jul 31 '05 #4
I looked at the HTML. View Source for the page shows:
_______________ ______
<html>
<head>
<head>
<body>

There are 18 messages on the server.<p><tabl e border=1 align=center
cellspacing=1>< tr><th>&nbsp;</th><th>Subject</th><th>From</th></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr></table>
</body>
</html>
_______________ ______
This may not correspond exactly to original code as I've been working
on it since posting.

Jul 31 '05 #5
[Please quote if you want further responses]

Rich_C wrote:
Thanks Dave -
Even if I only try to display one part of the email
(Subject, FromName, etc.) nothing is returned.


I can only assume the problem is with the POP3svg.Mailer object, which is
beyond the scope of ASP.
--
Dave Anderson

Unsolicited commercial email will be read at a cost of $500 per message. Use
of this email address implies consent to these terms. Please do not contact
me directly or ask me to contact you directly for assistance. If your
question is worth asking, it's worth posting.
Jul 31 '05 #6
I hate to revisit this old issue, but I have a question about how mail
servers assign email IDs. This script attempts to retrieve mail with
ID 1 to n with n being the number of messages on the server for the
account.

Can anyone tell me how Email IDs are assigned? Is it likely that the
first message isn't number 1 and therefore my script returns nothing?
If this is the case, is it possible to determine which email IDs are in
the mailbox so they can be retrieved?

If it makes a difference, the account in question is on a shared server
and the script does not produce any errors when it runs.

Aug 8 '05 #7

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

Similar topics

3
3273
by: laurie | last post by:
Hi all, I'm trying to help out a friend who has inherited a client with a PHP shopping cart application. Neither of us know PHP, but I've been muddling my way through, trying to get these old scripts working on a new server with the most recent version of PHP. I've pretty much taken care of all the various errors that were popping up. Most only pointed out out non-fatal undefined or assumed variables. I've been able to cure most of...
12
4107
by: Egil M?ller | last post by:
Is there any way to create transparent wrapper objects in Python? I thought implementing __getattribute__ on either the wrapper class or its metaclass would do the trick, but it does not work for the built in operators: class Foo(object): class __metaclass__(type): def __getattribute__(self, name): print "Klass", name
2
5750
by: Matt | last post by:
I'm new to Java but experienced with PL/SQL. I've found what appears to be strange behaviour (a bug?) when attempting to create java stored objects using the UNIX version of Oracle SQL*PLUS 8.1.7.3.0 with JServer 8.1.7.3.0. The reason it seams strange is that the problem only occurs with the UNIX version of SQL*PLUS, not the PC client version running on Windows 2000 but connected to the same database and schema. Can anyone shed any light...
6
6787
by: Andreas Lauffer | last post by:
I changed from Access97 to AccessXP and I have immense performance problems. Details: - Access XP MDB with Jet 4.0 ( no ADP-Project ) - Linked Tables to SQL-Server 2000 over ODBC I used the SQL Profile to watch the T-SQL-Command which Access ( who creates the commands?) creates and noticed:
5
9551
by: George Copeland | last post by:
This is a request for help fixing a SQL Server 2000/ADO problem on Windows XP. I would appreciate any useful assistance. PROBLEM: SQL Server access on my machine fails as follows: 1. All of my VB6 apps reference the following ADO typelib: Microsoft ActiveX Data Objects 2.7 Library Located at: c:\Program Files\Common Files\System\ADO\msado27.tlb
6
2998
by: Mica Cooper | last post by:
Hi, I have a series of Select menus on a page. I am trying to allow the user to click on the Select title and have it popup a help window. This works fine with the following code except that all the Select choices are lost. <A HREF="javascript:location='menu.jsp';window.open('menuhelp.jsp?menuID=5','me nuhelp',)">MenuTitle</A> I saw an example of a popup on a website that did not lose the menu choices.
2
6971
by: Jobs | last post by:
Download the JAVA , .NET and SQL Server interview with answers Download the JAVA , .NET and SQL Server interview sheet and rate yourself. This will help you judge yourself are you really worth of attending interviews. If you own a company best way to judge if the candidate is worth of it. http://www.questpond.com/InterviewRatingSheet.zip
2
4789
by: Vadim Malishev | last post by:
Hello, Can anybody help to solve the following problem? My Windows Service trying to access remote machine to get WindowsDirectory Property over Win32_OperatingSystem WMI class. Both servers are in the same Active Directory domain, so I create special active directory user and impersonate to it before invoke WMI. My code looks like:
0
9700
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
10310
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
10292
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
10068
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
9121
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
5498
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5627
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4275
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
2
3796
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.