please ignore this question
--
On 27/12/2008 00:28:44, amos - [email protected] wrote:
>hi
>until now i used TNT controls and functions to email unicode text, no
>matter what was the language, it was sent and received correctly and
>was always converted to UTF8. because D2009 has its own unicode
>support i no longer using TNT controls.
>with D2007 i used this:
> tmp := m.Lines.Text; //m is TTntRichdit
> htmlPart := Msg2.AddPart(MimePart);
> HTMLContent := TTntStringList.Create;
> Adapt :=
>TAnsiStringsForWideStringsAdapter.Create(HTMLContent); //taken from
>TNTClasses, obsolete now try HTMLContent.Text := <
>some text to send containing english and some other languages >
>Adapt.SaveToStreamEx(htmlPart.DecodedLines,CP_UTF8);
>htmlPart.Primary := 'text'; htmlPart.Secondary := 'plain';
> htmlPart.Description := 'plain text';
> htmlPart.Disposition := 'inline';
> htmlPart.CharsetCode := UTF_8;
> htmlPart.EncodingCode := ME_QUOTED_PRINTABLE;
> htmlpart.TargetCharset := UTF_8;
> htmlPart.EncodePart;
> htmlPart.EncodePartHeader;
> finally
> HTMLContent.Free;
> Adapt.Free;
> end;
>with D2009 im using:
> htmlPart := Msg.AddPart(nil);
> htmlPart.Primary := 'text';
> htmlPart.Secondary := 'plain';
> htmlPart.Description := 'plain text';
> htmlPart.Disposition := 'inline';
> htmlPart.CharsetCode := UTF_8;
> htmlPart.EncodingCode := ME_QUOTED_PRINTABLE;
> htmlpart.TargetCharset := UTF_8;
> htmlpart.PartBody.Text := < some text to send containing
>english and some other languages > htmlpart.DecodePart;
>the problem is that the result is not readable (gibberish), for
>example: english text, hebrew word: îùä - some more english text
>the above works perfectly with D2007 mode.
>i must add that the subject does work and is readable, the problem
>with the content (text)
>please advice or where can i have some samples i can learn with
>thanks
>--
------------------------------------------------------------------------------
_______________________________________________
synalist-public mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/synalist-public