trichview.com

trichview.support




Re: Copying HTML?


Return to index


Author

Message

Sergey Tkachenko

Posted: 04/22/2004 12:11:18


Hi,


Internet Explorer copies information to the Clipboard in several formats,

including RTF and HTML.

But for very complex documents (with nested tables) it fails to copy RTF.

By default, MS Word pastes HTML, RichViewEdit pastes RTF.

You can test pasting RTF from IE in MS Word - menu Edit | Paste Special,

choose Rich Text Format from the list.

You'll see the results very close to the results pasted in RichViewEdit.

Yes, RTF produced by IE does not have very good quality.


You need to use several addons to paste HTML in RichViewEdit. All of them

are free.

1) RVHTMLImporter - allows to insert and paste HTML.

http://www.trichview.com/resources/

RichViewActions support this component (read Install.txt for

RichViewActions, and the bottom of the document loaded by default in the

ActionTest demo).

HTML will be added in Insert|File, in Edit|Paste Special, and in Ctrl+V if

RTF is not present in the Clipboard or empty.

2) HTML files usually contain GIF and PNG images. Delphi does not support

them by default, but there are free third-party implementations that can be

used in RichView.

See the comments in Unit3.pas from RichViewActions

3) When you copy from the web page opened from the remote server (via http),

images are not in the Clipboard but must be downloaded.

RichViewActions can do it for you using Indy (included in new versions of

Delphi).

(read the bottom of the document loaded by default in the ActionTest demo)



> (ii) the actual HTML for the selected/copied segment of the web page (like

> in 'View Source' in IE).


It's not supported by default, but I can give a code returning it.





Powered by ABC Amber Outlook Express Converter