phohan [mailto:[EMAIL PROTECTED] wrote:

> My questions are:-
> 1) At the time I run the processing I have 10 emails to save. And once all
attachments are saved, the program will loop through my inbox and delete the
emails. Will I be deleting 11 emails instead? Meaning that my 1st loop, my
inbox has 10 emails but during the 2nd loop, 1 new email received
(attachment not
saved) and the program deleted that email. Will this scenario happens? If
yes, can someone guide me how do I prevent this matter from happenning?

For lLoop = 1 to oFldr.Items.Count
  'Put code here to save attachment from oFldr.Items(0)
  oFldr.Items(0).Delete
Next lLoop

My MAPI syntax is probably slightly wrong (I don't remember if the
collection
is 0 based or 1 based), but the point I am making is if you save the
attachment and then delete the e-mail in the same loop, then you can
be sure that you will only be deleting e-mails for which you have saved
the attachment.

Adelle.




------------------------ Yahoo! Groups Sponsor --------------------~--> 
Yahoo! Domains - Claim yours for only $14.70
http://us.click.yahoo.com/Z1wmxD/DREIAA/yQLSAA/k7folB/TM
--------------------------------------------------------------------~-> 


'// =======================================================
    Rules : http://ReliableAnswers.com/List/Rules.asp
    Home  : http://groups.yahoo.com/group/vbHelp/
    =======================================================
    Post  : [EMAIL PROTECTED]
    Join  : [EMAIL PROTECTED]
    Leave : [EMAIL PROTECTED]
'// =======================================================
 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/vbhelp/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 

Reply via email to