ditte
  • ditte
  • 61.25% (Friendly)
  • Member Topic Starter
14 years ago
What I like to do:

1. chose a folder (with selectfolder) - it works
2. search for email [postnr and ok or error] with searchmail - it works
3. if email found [equal = postnr and also is ok] move the email to a archive folder [like "faxsendok"]

4. now I must search the folder "faxsendok" to get the Imap4Folder

5. get the mail.content
6. mailclient.Append to the new folder
7. mailclient.Delete
8. mailclient.Expunge

Is there a fast way for step 4. to get the Imap4Folder of "faxsendok" like thread "Imap folders,fast search" ?
ivan
  • ivan
  • 100% (Exalted)
  • Administration
14 years ago

1. Yes, you can create the IMAP4 folder object like like this:


Dim oFolder As New Imap4Folder
oFolder.ServerPath = "Deleted Items"
oFolder.FullPath = "Deleted Items"

then you can use it in Append method directly.

2. If your archive folder is in the same IMAP4 account. You should use
MailClient.Copy method  instead of "get content" and "append". It is much faster.

EXPLORE TUTORIALS

© All Rights Reserved, AIFEI Software Limited & AdminSystem Software Limited.