Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Print content of TStringGrid - question

72 views
Skip to first unread message

Bert Prins

unread,
Nov 18, 2003, 8:25:45 AM11/18/03
to
Hello.

I want to send the content of a TStringGrid to a printer. I've tried this:

Printer.BeginDoc;
sgStructure.PaintTo(Printer.Handle, 10,10);
Printer.EndDoc;

I must say: it works, but the result is about 2 x 2 cm !!! Un-readable. Do I
something wrong or is there a better way to print the content of a
TStringGrid?

Thanks,

Bert Prins


Sander Martens

unread,
Nov 18, 2003, 12:32:05 PM11/18/03
to
Hi Bert,

I use QuickReport.


"Bert Prins" <prin...@hotmail.com> schreef in bericht
news:3fba1dd9$0$58707$e4fe...@news.xs4all.nl...

Mike Shkolnik

unread,
Nov 18, 2003, 2:05:35 PM11/18/03
to
Check TSMPrintStringGrid component: http://www.scalabium.com/smr

--
With best regards, Mike Shkolnik
E-mail: mshk...@scalabium.com
WEB: http://www.scalabium.com

"Bert Prins" <prin...@hotmail.com> wrote in message
news:3fba1dd9$0$58707$e4fe...@news.xs4all.nl...

Maarten Wiltink

unread,
Nov 19, 2003, 12:28:53 AM11/19/03
to
"Bert Prins" <prin...@hotmail.com> wrote in message
news:3fba1dd9$0$58707$e4fe...@news.xs4all.nl...

> I want to send the content of a TStringGrid to a printer.

Without going into details of how to fix it, what went wrong is
that you didn't correct for the resolution of the canvas.

Groetjes,
Maarten Wiltink


J French

unread,
Nov 19, 2003, 4:52:49 AM11/19/03
to

Yes, I also figured that, but could not see any obvious solution
- printing in Delphi is one of my weak points
- could you provide a pointer

Bert Prins

unread,
Nov 19, 2003, 6:46:24 AM11/19/03
to
Thanks for the answers. But because my aversion against QReport and because
I want one print-procedure for several grids I found another solution. Now I
copy the contents of the stringgrid into a TMemo and print the contents of
that memo.

"Bert Prins" <prin...@hotmail.com> schreef in bericht
news:3fba1dd9$0$58707$e4fe...@news.xs4all.nl...

Sander Martens

unread,
Nov 19, 2003, 6:36:58 PM11/19/03
to
Hi Bert,

Though you're not using QuickReport you might try Rave Reports, it's in the
components pallette. I haven't studied it yet but it looks very
professional.

Kind Regards Sander'

"Bert Prins" <prin...@hotmail.com> schreef in bericht
news:3fba1dd9$0$58707$e4fe...@news.xs4all.nl...

0 new messages