printing chart,graph not visible and bad properties values

TeeChart for ActiveX, COM and ASP
Post Reply
Michel.R
Newbie
Newbie
Posts: 3
Joined: Wed Nov 26, 2003 5:00 am
Location: Rennes France

printing chart,graph not visible and bad properties values

Post by Michel.R » Fri Feb 27, 2004 8:53 am

I'd like to submit you a problem encountered after printing charts.
1- show a graph in a form
2- Print the Graph with Graph.Printer.PrintChart()
3- Change the Graph Property Visible to .F.
4- Change Title font size property to 20 (Any text font size is concern).
5- Change the Graph Property Visible to .T.
Thus, the Graph.Header.Font.size=75 instead of 20.
This action does not appear by printing the chart through the preview panel.

If the AutoRepaint property is false before changing the graph properties
and is set to True after, the behevior is Similar.
We have find a issue by using the Repaint method just after the printChart()
Method.

Thanks for any response,
Bernard
France

Pep
Site Admin
Site Admin
Posts: 3278
Joined: Fri Nov 14, 2003 5:00 am
Contact:

Post by Pep » Mon Mar 01, 2004 12:29 pm

Hi Bernard,

to solve this you should add the following line after print :
TChart1.Environment.InternalRepaint

i.e:

Code: Select all

With tchar1
    .Printer.PrintChart
    .Environment.InternalRepaint
    .Visible = False
    .Header.Font.Size = 20
    .Visible = True
End With

Post Reply