Re: Error retrieving PlainText from a mail - WeOnlyDo Discussion board

Re: Error retrieving PlainText from a mail (General questions)

by GLlort, Monday, May 16, 2005, 20:56 (7130 days ago) @ wodSupport

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


Complete thread: