Page 1 of 1

TRichViewEdit HTML conversion

Posted: Mon May 02, 2011 12:59 pm
by Marcer
Hi,

I am using the TRichViewEdit function SaveHTMLToStream to convert the content of my TRichViewEdit to HTML. Then, I send the HTML code via email using Indy component.

My problem is that when I convert my text into HTML, each line of code contains font information even if the information are the same and even if they were already initialize in a previous HTML tag.

For example,

Code: Select all

Hi, 
This is an exemple of HTML convertion.
You may see that, for example, each line initialize the HTML font color.
This cause some spam filter to think that the HTML code was generated via some spam generator wich cause my email to be flag as spam.
Thank you for your help.
translate into:

Code: Select all

<html>
<head>
    <title>Courriel</title>
</head>
<body bgcolor="#ffffff" leftmargin="1" topmargin="1" rightmargin="1" bottommargin="1">
    <font size="1" color="#000000" face="MS Sans Serif">
        <div>
            <font color="#000000">Hi,</font>
        </div>
        <div>
            <font color="#000000">
                <br>
            </font>
        </div>
        <div>
            <font color="#000000">This is an exemple of HTML convertion.</font></div>
        <div>
            <font color="#000000">
                <br>
            </font>
        </div>
        <div>
            <font color="#000000">You may see that, for example, each line initialize the HTML font color.</font></div>
        <div>
            <font color="#000000">
                <br>
            </font>
        </div>
        <div>
            <font color="#000000">This cause some spam filter to think that the HTML code was generated via some spam generator wich cause my email to be flag as spam.</font></div>
        <div>
            <font color="#000000">
                <br>
            </font>
        </div>
        <div>
            <font color="#000000">Thank you for your help.</font></div>
    </font>
</body>
</html>
Is there a way to not repeat the color information for each line?

Posted: Mon May 02, 2011 3:53 pm
by Sergey Tkachenko
Strange, please send me a sample of the original document in RVF format.
(to richviewgmailcom)