Example Printing Embedded Charts

Vertex42 The Excel Nexus

Professional Excel Templates

Get Instant Access

We can now implement the PrintCharts feature of our SRXUtils application. This is designed to provide a list of the embedded charts in the active workbook, so the user can select from this list and print the selected charts. (To print a chart sheet, use the PrintSheets utility.)

Implementing the PrintCharts utility is similar to implementing the PrintSheets and PrintPivotTables utilities, which we did earlier in the book. At the present time, this print utility, located in the Print.utl add-in, simply displays a message box. To implement this feature, we want the utility to first display a dialog box, as shown in Figure 21-32.

Figure 21-32. Print Charts dialog

Figure 21-32. Print Charts dialog

The list box contains a list of all embedded charts in the active workbook. The user can select one or more charts and hit the Print button.

The following are the steps to create the print utility. All the action takes place in the Print.xls workbook, so open this workbook. When the changes are finished, you will need to save Print.xls as Print.utl as well. If Print.utl is loaded, the only way to unload it is to unload the add-in SRXUlils.xla (if it is loaded) and close the workbook SRXUtils.xls (if it is open).

Was this article helpful?

0 0
Black Jack Tactics Conquering The Game In Casinos

Black Jack Tactics Conquering The Game In Casinos

So, you want to learn how to play Blackjack. Youre in good hands. There is no better ship to chart those learning waters than the one youre riding on right now.

Get My Free Ebook


  • angelico
    How to print charts in vba?
    9 years ago

Post a comment