Re: That pesky first item

Return to index



Sergey Tkachenko

Posted: 02/18/2005 21:51:16

When building document, you should use viewer-style methods (i.e. methods

introduced in TRichView, not in TRichViewEdit). They can be called for

unformatted documents after Clear.

Which method generates the exception? I'll try to suggest an alternative

> Hi there,


> I'm trying to build a document in an empty TRichViewEdit, item by item,

> reading from an XHTML DOM. This is working well except that for every

> RVData (the main control, or any contained table cells), there's always

> an initial empty paragraph item at the beginning, leading to an

> unnecessary blank line. If I call Clear before starting to add new

> items, then I get errors when adding items (because the control is

> unformatted, presumably); if I call Clear, then Format, I get that pesky

> item back again! If I delete the first item after building the document,

> to get rid of the blank line, then the "real" first paragraph style

> reverts to ParaStyles[0], which is not necessarily right.


> I've tried everything I can think of here -- any ideas?


> All help appreciated,

> Martin

Powered by ABC Amber Outlook Express Converter