Web Browser component in C#

  • Thread starter Thread starter Bryan
  • Start date Start date
B

Bryan

I have a AxWebBrowser componet in my c# app. I want to be able to get
rid of the header and footer when I print it. I got it so that a button
can open the print and page setup dialogs. So in the page setup dialog
but you can get rid of this and then print, but that isn't exactly what
I want. Reading stuff, it looks like I want to change the default
template of IE. The ExecWB() method takes an SHDocVw.OLECMDID which is
an enum that has a SETPRINTTEMPLATE value, but I can't seem to use the
reference parameters at the end that I'm supposed to use to set it.
Does any one have any ideas?

--Bryan
 
Bryan said:
I have a AxWebBrowser componet in my c# app. I want to be able to get
rid of the header and footer when I print it. I got it so that a button
can open the print and page setup dialogs. So in the page setup dialog
but you can get rid of this and then print, but that isn't exactly what
I want. Reading stuff, it looks like I want to change the default
template of IE. The ExecWB() method takes an SHDocVw.OLECMDID which is
an enum that has a SETPRINTTEMPLATE value, but I can't seem to use the
reference parameters at the end that I'm supposed to use to set it.
Does any one have any ideas?

You might like to look at the htmleditor:

http://www.itwriting.com/htmleditor/index.php

Has print template support; I believe you can also do this with the
AxWebBrowser.

Tim
 
Back
Top