Hi, how can I apply formatted HTML to TSRichViewEdit?
I'm using the following code, and in some places it works, and in others it simply replaces <b></b> with ****
//obtendo o retorno HTML
htmlStreamRetorno := TStringStream.Create;
memHTMLString.Clear;
memHTMLString.Text := _fieldvalue;
memHTMLString.Lines.SaveToStream(htmlStreamRetorno,TEncoding.UTF8);
htmlStreamRetorno.Position := 0;
//convertendo o html para docx
docXStream := TStringStream.Create;
SRichViewEditAux.Clear;
SRichViewEditAux.ActiveEditor.LoadHTMLFromStream(htmlStreamRetorno,'',CP_UTF8);
SRichViewEditAux.ActiveEditor.SaveDocXToStream(docXStream,false);
docXStream.Position := 0;
in TSRichViewEdit:
RichViewEdit.InsertDocXFromStreamEd(_fieldValue);
Notice that he correctly changed the text to bold at the beginning, but then failed to do so for the names of the people.
applying HTML text
Re: applying HTML text
I found the problem and it was a flaw in my code, thank you.