Page 1 of 1

How to change the preview window title

Posted: Tue Dec 06, 2005 1:31 am
by 9529132
Hi, there,

I wrote an dialog-based app named TeeChartTest to test the print and print preview function and I added a botton on the dialog to call m_chart1.GetPrinter().ShowPreview(); It worked fine except that the title of the preview window is "Teechart Print Preview", not what I expected to be "TeeChartTest Print Preview". Is there any way to change the preview window title? Thank you!

Posted: Fri Dec 09, 2005 11:34 am
by Pep
Hi David,

yes, it can be changed, but you've to add a TPreviewer component into the form, assign it to the Chart (using ChartLink) and then use the PreviewTitle property to set a customized title i.e. :

TeePreviewer1.SetPreviewTitle(customtitle);
TeePreviewer1.ShowPreview();