Page 1 of 1

multichart to 1 page pdf export?

Posted: Tue Mar 21, 2017 11:14 pm
by 16677938
I tried something similar to the example above and it works. I'm using TChart 2015 ocx, ActiveX.

I added a TeePreviewPanel at Design time to a blank CDialog. I then added N charts onto the PreviewPanel at runtime and placed them relative to each other.

How can I give the user the option to select a printer so that he/she can select a pdf file to print or any other printer? i.e. I want to display the Print Previewer from a button on the CDialog.

PreviewPanel->PrintPage() prints a page to the default printer without letting the user select the printer.

Any help will be appreciated.

Re: multichart to 1 page pdf export?

Posted: Wed Mar 22, 2017 1:56 pm
by 10050769
Hello nbp,

I think the best option for you is taking a look in the Visual C++ examples, specifically to Printing example. The example is in the path below:
%Program Files (x86)%\Steema Software\TeeChart Pro v2017 ActiveX Control\Examples\Visual C++\Version 6 \Printing

In the example, is used a Menu to allow the users select the printer they want.

Hoping it helps you, otherwise don't hesistate to contact us.

Thanks in advance

Re: multichart to 1 page pdf export?

Posted: Wed Mar 22, 2017 8:32 pm
by 16677938
Thanks. I didn't have access to the View class to use the built in printing support such as the OnPrint() method so couldn't use that specific example.

But I found the following link http://www.teechart.net/support/viewtop ... 817#p62520very useful and now I've got it working correctly. The user can either select a printer or a pdf and then do a PrintPage on the TeePreviewPanel object.

Thanks.