-
Printing
Ok I had a project all finished and working till this morning when I got told that they wanted to change something, drop the use of Excel. Got to love when a project gets changed for no good reason. :mad:
Anyway my program creates a HUGE report, something like 8000 pages. What I had working was the report was getting put in Excel. Then the user could go in and work with the data, or print it, etc. But now they want the data to go strait to the printer.
So I need to know whats the best way to print to a printer (C++)something that well need to be formatted, with headers, columns, totals, etc.
If someone has some sample code or a wrapper class to help me do the ASAP that would be great. The clock is against me.
-
Are they mad?
Ok, there are a few printer functions that you use to get a HDC that references the printer. Then you draw to this HDC. There are two functions to start and to end a page.
But the thing is, you must now do all the formatting yourself. That's going to take a while.
-
Honestly I think they went and did a big hit of crack then decieded that Excel wasnt going to work. It was all done, I was going to fix 2 stupid bugs then make the install shield for it and call it a day. Do you know how tuff it is to figure out how to make Excel do things. I couldnt find many examples anywhere. Stupid MS makes it really hard to do things like that outside of VB :mad:
Now they want this stuff as a raw print out. Luckily there is nothing more than text. I am making a wrapper using WritePrinter(). So far so good. But formatting is going to be my biggest problem. ARG I hate bosses sometimes.
-
You never know, they might suddenly change their fractured minds again and then they'll be blown away when you save everyone's ass with your excel prog. :D
-
Yeah, make sure you have a backup of the current version.
-
Corned, at last we agree on something heh, :)