473,320 Members | 1,976 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Another HTML Printing Question

Hi,

I need to have the ability to take HTML files and print them out to a
printer (each document may have to be sent to a different printer). This
needs to be done without user interaction (i.e. some type of batch/server
process). Here is what I tried so far:

1. Automate Word within a service. Word would open the HTML file and then
print it. This seems to work consistently only when the service is running
on a workstation. It also seems to fail with certain print drivers.

2. Create a application that wraps the AxWebBrowser control. This would
load up the HTML document and when the DocumentComplete event is fired, it
would print using the ExecWB() method. This seemed to work very nicely, but
every once in awhile, the ExecWB call would hang. There were even times
after executing that call that the application would just blow up -- no
exceptions; no Dr. Watsons, nothing.

My goal is to have some type of process in place where we can drop HTML
files into a directory (or some type of definition file that describes the
document, where it is supposed to go, etc.) and print it. Does anybody know
of any code snippets or even some controls that would allow me to do this?
Again, I would prefer to do this within a service, but if I can't, then I
can't.

By the way, how would I be able to get a context for the AxWebBrowser
control so that it would render the document?

Thanks a bunch!
cj
Nov 17 '05 #1
0 976

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

10
by: Andrew | last post by:
I am making a web site and I am using ASP because of its templating capabilities. My footer is an include file, for obvious reasons. I can't use an include file for the header, because, while the...
3
by: Tim Mierzejewski | last post by:
I'm having trouble assigning a string to a character array. Here's the applicable code: #include <iostream> #include "Creature.hpp" // Includes Creature class using namespace std;...
9
by: Jody Gelowitz | last post by:
I am trying to find the definition of "Safe Printing" and cannot find out exactly what this entitles. The reason is that I am trying to print contents from a single textbox to no avail using the...
18
by: Phil Powell | last post by:
I am trying to print out an HTML document that has MARGINWIDTH set to 1, however, upon printing, HTML table cell contents are cut off, for exmample: <table border="0" width="780"> <tr>...
4
by: Alex | last post by:
I need to display html info on an Access form. To do this I am using the Micorsoft Web Browser control which uses shdocvw.dll The problem with this is that a. the control is not resizable....
9
by: Sean McKaharay | last post by:
Since no one can answer the following question: I have a issue. I need to create a command line application/or windows application that will take 2 parameters and will print to the default...
3
by: Ahmad Abu-Raddad | last post by:
Hey Guys, Does anyone knows of a way to print HTML source directly to the printer (Server Side)?. I tried the PrintDocument class and the e.Graphics.DrawString and e.Graphics.DrawImage() but...
0
by: Martin K | last post by:
Hello all..thanks for everyone's advice regarding my SHBrowseForFolder API problem, I was able to put together a public class that runs great! But I have another migration headache regarding the...
1
by: Jorgen Bodde | last post by:
Hi All, I am at a loss. This is slightly OT because it concerns Windows and HTML printing. I would like to print a HTML document from Python, but not showing the printing dialog. After numerous...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.