0

I have a program for data acquisition and process control. I use TeeChart for real time plotting of data. I also have a legend window on top of the chart. I can print or save to disk the TeeChart, but would prefer to print/save the entire screen including the legend window. This is written in Delphi 7. I have tried several suggestions from other websites, but the us keybd_event procedures that are, apparently, not supported in Delphi 7. I could require the user to use the Print Screen key, but would prefer to use the button on the plot so I can remove the control buttons for the print function and then restore them after the screen is plotted. Any suggestions will be greatly welcomed. Thanks.

2
Contributors
3
Replies
4
Views
6 Years
Discussion Span
Last Post by dlhale
0

Have you tried copying the canvas of the form containing the TeeChart to the printer's canvas?

0

Have you tried copying the canvas of the form containing the TeeChart to the printer's canvas?

No, I haven't tried that and am not sure how to do it. I will look into that as a possibility, but it will be treading new ground for me. Thanks for the suggestion, I'll see what I can do.

TRCSr

0

It would look something like this

Printer.Canvas.CopyRect(PrtRect, Form.Canvas, FormRect);

PrtRect and FormRect are TRect.
FormRect defines the area of the Form that you want printed.
PrtRect defines where an the page the Form image goes.

Learning to control the printed page at this level is actually a lot of fun.

Best wisshes to you.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.