I receive mail in MIME format with special characters (ăîâşţ) in Body field. The mail is only text, not attachments.
I want to read the text from body and save to another field in another document, for that i have a simple agent. The problem is that when run the agent from the client (action menu), all characters are converted ok but when the agent is running scheduled on server the characters are wrong (something like this: ÄîâşţÄ).
Any ideas how to fix this without using MimeEntity?
The body field is like this:
Field Name: Body
Data Type: MIME Part
Data Length: 65 bytes
Seq Num: 1
Dup Item ID: 0
Field Flags: SIGN SEAL
"Content-Transfer-Encoding: quoted-printable
Content-Type: text/plain; charset=utf-8
=C4=83=C3=AE=C3=A2=C5=9F=C5=A3=C4=82=C3=8E=C3=82=C5=9E=
=C5=A2 abcd
"
The agent:
Dim session As New NotesSession
Dim db As NotesDatabase
Dim view As NotesView
Dim col As NotesDocumentCollection
Dim doc As NotesDocument
Dim item As NotesRichTextItem
Dim content As String
Set db = session.CurrentDatabase
Set view = db.GetView("InboxAll")
Set col = view.GetAllDocumentsByKey("Memo")
If col.count <> 0 Then
Set doc = col.GetFirstDocument
While Not (doc Is Nothing)
Set item = doc.GetFirstItem( "Body" )
content = item.GetUnformattedText
‘’‘’‘’ save content to another doc
Set doc = col.GetNextDocument(doc)
Wend
End If