Render HTML in memo control to print a report

T

toni

Hi,
I have some MEMO fields wich contains HTML code (very simple code, <strong>
<i> lables and so).
I need to print them in a report RENDERED as they would be sown in a web
browser. ¿is there any control to do it?
Thanks a lot.
 
S

Stephen Lebans

The short answer unfortunately is no. You would require an ActiveX
control on the report to display the HTML source.

The MS Web Browser control can be used to display the HMTL on a form but
it will not ouput it's contents during the printing process for a Form
or Report. The control supports an output method and therefore can
render its contents directly to the printer independantly of the
report/form.

--

HTH
Stephen Lebans
http://www.lebans.com
Access Code, Tips and Tricks
Please respond only to the newsgroups so everyone can benefit.
 
T

toni

Thanks Stephen.
I'm thinking on something... What about WORD? if i feed an ole control
with the contents of the memo field, MSWord would render a bit of HTML code?
What do you think about this silly thought? could you even understand my
english phrases? :)
Thanks again in advance.
 
T

toni

Please, i need your help...


toni said:
Thanks Stephen.
I'm thinking on something... What about WORD? if i feed an ole control
with the contents of the memo field, MSWord would render a bit of HTML code?
What do you think about this silly thought? could you even understand my
english phrases? :)
Thanks again in advance.
 
S

Stephen Lebans

I don't believe you can change the contents of the OLE control at
runtime. I'm not 100% sure as it has been a while since I have tested
this.
There is no simple alternative solution. If your HTML is basic stuff
then you could insert my RTF control on your report and:
1) Copy the HTML string to the Clipboard. WIndows will automatically
convert it to RTF.
2) Copy the converted RTF from the Clipboard to my RTF control


--

HTH
Stephen Lebans
http://www.lebans.com
Access Code, Tips and Tricks
Please respond only to the newsgroups so everyone can benefit.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top