开发者

Printing an external file in its own printing routine

开发者 https://www.devze.com 2022-12-27 04:03 出处:网络
I basically have an application that generates reports in a .html file, I use a .html file for the ease of making tables and formatting text.

I basically have an application that generates reports in a .html file, I use a .html file for the ease of making tables and formatting text.

Now I would like to introduce a way of printing the reports from my program. Because I us开发者_如何学Pythone a .html file, the formatting would not the correct if I was to print it directly from my application (as far as I know). For this reason, I would like to print it just like my web browser would have in order to keep the tabular data intact and the text formatting.

Does anyone know a way to do this?

Thank you.


CSS can do everything you need. You may want to open the document in its own window (or Iframe) with its own stylesheet specifically designed for your report.

See: Good rules for setting up print css?

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号