Welcome Guest. Please Login or Register. Apr 5th, 2018, 10:23pm
ATTENTION MEMBERS: Conforums will be closing it doors and discontinuing its service on April 15, 2018. Ad-Free has been deactivated. Outstanding Ad-Free credits will be reimbursed to respective payment methods.
If you require a dump of the post on your message board, please come to the support board and request it.
The way I would probably do it is to write all my 'printing' routines so that they take as a parameter the output DC. Then when printing normally I would pass @prthdc% as the parameter, and when doing the Print Preview I'd pass a memory DC that I had created for the purpose. Richard.
To be honest, I'm not sure what most of this means as I haven't done much with device contexts specifically. Any printing I've done has been directly through VDU2, etc. or through creating an HTM document and then executing that file. So doing this with @prthdc% is new to me. However, I'll have a go and see what I can do. Any pointers would be appreciated, though.
Any printing I've done has been directly through VDU2, etc.
In that case you might be able to do the Print Preview by creating a memory DC compatible with @prthdc%, temporarily setting @prthdc% to your temporary DC, doing the normal print output, and then restoring @prthdc% to its previous value (followed by blitting the temporary DC to your preview window of course).
It's not something I've tried, but it sounds relatively straightforward and also quite interesting. Maybe if it can be made to work it could be developed into a BB4W 'print preview' library. If that's something you would like to attempt I'm sure the BB4W user community would be extremely grateful!