Search The ForumSearch   RegisterRegister  LoginLogin

MailBee.NET Objects

 AfterLogic Forum : MailBee.NET Objects
Subject Topic: mhtml:mid:// Post ReplyPost New Topic
Author
Message << Prev Topic | Next Topic >>
boranin
Newbie
Newbie


Joined: 29 September 2007
Location: New Zealand
Online Status: Offline
Posts: 32
Posted: 15 February 2008 at 6:26am | IP Logged Quote boranin

I am geting mhtml:mid:// as part of the inline attachment link after msg.GetHtmlAndSaveRelatedFiles. Apparently, this happens only with emails sent from OE. Do you have any solution for this or am I doing something wrong here?

Part of the code:

Dim strMailImageServer As String = "Components/MailImageServer.aspx?"
                strBody = msg.GetHtmlAndSaveRelatedFiles(strMailImageServer, _
                     VirtualMappingType.Dynamic, MessageFolderBehavior.CreateOnly)

Regards,
Alex
Back to Top View boranin's Profile Search for other posts by boranin
 
Andrew
AfterLogic Support
AfterLogic Support


Joined: 28 April 2006
Location: United States
Online Status: Offline
Posts: 1189
Posted: 15 February 2008 at 6:41am | IP Logged Quote Andrew

Could you please provide us with a sample of such message? Use Support Form for this purpose.

Best regards,
Andrew
Back to Top View Andrew's Profile Search for other posts by Andrew
 
boranin
Newbie
Newbie


Joined: 29 September 2007
Location: New Zealand
Online Status: Offline
Posts: 32
Posted: 15 February 2008 at 7:33am | IP Logged Quote boranin

Sorted with the following:
Dim objRegex As Regex
                strBody = objRegex.Replace(strBody, """mhtml:mid://[0-9]*/!", "")

Will forward te body to support as well.

Now, my next issue is with imp.DownloadEntireMessage. It marks message as read, regardless of the fact folder is opened imp.ExamineFolder. Message would come unread again in a few minutes time.
What is the explanation here? I know I am missing something.
Regards,
Alex
Back to Top View boranin's Profile Search for other posts by boranin
 
Alex
AfterLogic Support
AfterLogic Support
Avatar

Joined: 19 November 2003
Online Status: Offline
Posts: 2206
Posted: 15 February 2008 at 8:24am | IP Logged Quote Alex

Quote:
Will forward te body to support as well.

Looking forward to that, thanks.
Quote:
Now, my next issue is with imp.DownloadEntireMessage. It marks message as read, regardless of the fact folder is opened imp.ExamineFolder.

Well, this indicates the server incorrectly implements IMAP protocol in this part. The problem is that common email clients do not use EXAMINE to keep mailbox read-only. Since IMAP protocol is very complex, many mail server vendors implement only its part which is used by common email clients and pay little attention to the rest of the features.

To workaround this, you can use Imap.DownloadEnvelopes(messageIndexSet, indexIsUid, parts, bodyPreviewSize) passing very large number (e.g. 999999999) as bodyPreviewSize value. This will return you entire messages because all emails are less than 999999999 bytes but the server will keep thinking it's returning the message header only and thus won't discard unread status. DO not forget to specify MessagePreview flag in parts parameter.

Regards,
Alex
Back to Top View Alex's Profile Search for other posts by Alex
 

If you wish to post a reply to this topic you must first login
If you are not already registered you must first register

  Post ReplyPost New Topic
Printable version Printable version

Forum Jump

Powered by Web Wiz Forums version 7.9
Copyright ©2001-2004 Web Wiz Guide