Assigning object names to charts

abasu

New Member
Joined
Apr 6, 2002
Messages
1
Hi,

Have 2 queries regarding this matter:
(Am using Excel 97)
1. Is it possible to assign charts a name(ie instead of bing called "Chart1" in VB, i'd like to call it something else.) I have noticed that an individual chart does not have any properties. It seems that only a chart sheet, or a work sheet has properties. is that becasue charts are not stored as objects in excel??

2. I have a worksheet with 36 charts in it. i would like to be able to select any combination of these charts and print them, without having to click on them individually. is this at all possible, as i have noticed that performing a "ctrl + select" does not select the individual chart.

Your help would me most appreciated!

Thanx in advance!

ABASU
 

Excel Facts

Excel Wisdom
Using a mouse in Excel is the work equivalent of wearing a lanyard when you first get to college
Hi abasu


Charts on Worksheets are still Objects, they are embedded in the sheet and as such become a member of the holding sheet. So to change the name via code use:

Sheet1.ChartObjects(1).Name = "MyChart"

Or to do so manually the easiest way is to Display the "Drawing Toolbar" select the "Select Objects" arrow and select the chart. Now just type a new name in the "Name box, left of the "Formula bar".

To print chosen charts use:

Sheet1.ChartObjects("MyChart").Chart.PrintOut
 
Upvote 0

Forum statistics

Threads
1,213,531
Messages
6,114,167
Members
448,554
Latest member
Gleisner2

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top