Error retrieving PlainText from a mail (General questions)

by GLlort @, (7291 days ago)

Hello,

I'm trying the wodMilBox component for an application that need to read EML messages from Exchange server.

I have de EML message and I can open and read the message width wodMailBox component. I get correctly his attachments and data (from, to, date, etc...) but when I trying to read the PlainText property, an error occurs. The message is:

80004005 - Automation Error

I'm developing this app using VB6 SP6 (Spanish language) under WIndows XP Pro.

Thank's and regards from Barcelona (Spain)

Gerard

locked

Re: Error retrieving PlainText from a mail

by Jasmine, (7291 days ago) @ GLlort

Gerard,

80004005 doesn't look like our error, it could be something else involved here. Any chance you could send me exact code you use, and possible that email message that causes trouble, to techsupport@weonlydo.com so we could check it out and give better answer?

locked

Re: Error retrieving PlainText from a mail

by GLlort @, (7291 days ago) @ Jasmine

The code like this:

Set oMail = CreateObject( WeOnlyDo.wodMailboxCom )
oMail.FileName = sFile
oMail.Lock

If oMail.Messages.Count > 0 Then

tMessage.FromName = oMail.Messages(0).FromName
tMessage.FromAddress = oMail.Messages(0).FromEmail
tMessage.ToName = oMail.Messages(0).ToName
tMessage.ToAddress = oMail.Messages(0).ToEmail
tMessage.DateRecv = Format$(oMail.Messages(0).Date, dd/MM/yyyy hh:mm:ss )
tMessage.Subject = oMail.Messages(0).Subject
If oMail.Messages(0).Parts.Count > 1 Then
For iCont = 0 To oMail.Messages(0).Parts.Count - 1
tMessage.Body = tMessage.Body & oMail.Messages(0).Parts(iCont).PlainText
Next
Else
tMessage.Body = oMail.Messages(0).HTMLText
End If

End If
oMail.Unlock
Set oMail = Nothing

...but when I call Lock method, PlainText property appears in the watch window with the mentioned automation error...(??). I think that is

locked

Re: Error retrieving PlainText from a mail

by Jasmine, (7291 days ago) @ GLlort

Gerard,

I have to kindly ask you once again to send that code to our email techsupport@weonlydo.com. As you have noticed, forum posts don't really keep it nice :) and besides, it doesn't help if we don't have original email message that you are trying to open with your code. So, I would appreciate if you could send that code AND the message that causes trouble to our email, please.

Thanks!

locked

Re: Error retrieving PlainText from a mail

by GLlort @, (7288 days ago) @ Jasmine

Thanks for all!

Now I can read PlainText property!

Gerard

locked