vb.net - Easiest way to add a Header and Footer to a Printing.PrintDocument (.Net 2.0)? -


what's easiest way add header , footer .net printdocument object, either pragmatically or @ design-time?

specifically i'm trying print 3rd party grid control (infragistics gridex v4.3), takes printdocument object , draws it.

the resulting page contains grid , it's contents - add header or title identify printed report, , possibly footer show printed it, when, , ideally page number , total pages.

i'm using vb.net 2.0.

thanks help!

the printdocument object fires printpage event each page printed. can draw text/lines/etc print queue using printpageeventargs event parameter:

http://msdn.microsoft.com/en-us/library/system.drawing.printing.printdocument.aspx

dim withevents when pass grid, can handle event.


Comments

Popular posts from this blog

windows - Why does Vista not allow creation of shortcuts to "Programs" on a NonAdmin account? Not supposed to install apps from NonAdmin account? -

c++ - How do I get a multi line tooltip in MFC -

unit testing - How to mock PreferenceManager in Android? -