Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to retrieve specific messages with pop3 ?
Message
General information
Forum:
Visual FoxPro
Category:
West Wind Web Connection
Miscellaneous
Thread ID:
00738231
Message ID:
00739675
Views:
20
You need to use GetMessageHeader() to retrieve the subject and Message Id in the first pass, then go back and grab just the message you want with GetMessage(). You should probably use the MessageId not the number since hte number will change unless you stay connected to the POP3 server the whole time...

Basic thing is Use GetMessageHeader() to check the message header, then call GetMessage() to retrieve the full message. If you do this all in the same pass you can do this with the same index.

If the messages are not big in general you probably don't need to worry about this and just use GetMessage() instead.

+++ Rick ---


>I am trying to read only messages with specific subject:
>
>IF loPOP.Connect()
>
> *lnMsgs = loPop.GetmessageHeader()
> lnMsgs = loPop.GetMessages()
>
> IF lnMsgs > 0
> For x = 1 to lnMsgs
> WAIT loPop.aMessages[x].csubject WINDOW
> ENDFOR
> ENDIF
>ENDIF
>
>If I use getmessageHeader instead of getmessages, I have only empty emails. I want to read only the header, see if the subject is = "ABC" and then download only these.
>
>Any suggestions ?
>
>Thanks
>
>Eric
+++ Rick ---

West Wind Technologies
Maui, Hawaii

west-wind.com/
West Wind Message Board
Rick's Web Log
Markdown Monster
---
Making waves on the Web

Where do you want to surf today?
Previous
Reply
Map
View

Click here to load this message in the networking platform