Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.charting
tom tom is offline
external usenet poster
 
Posts: 570
Default Chart object number

I have a number of charts in my worksheet that I would like to copy to a word
document. I am thinking the best way is to:

1. select the chart object
2. copy it
3. Tthen open a Word doc (not sure about the code for this)
4. paste it in the word doc

How can I get the chart object number to select the chart? for example if I
have 200 charts they are not always numbered sequentially from 1-200
depending on how many times the charts are created. I may have a chart 299,
then a chart 333. How do I go the chart object number to be able to
reference it and select the chart.

  #2   Report Post  
Posted to microsoft.public.excel.charting
external usenet poster
 
Posts: 6,582
Default Chart object number

You could manually or programmatically rename the chart objects
(http://peltiertech.com/Excel/ChartsH...meAChart.html). If the charts
are created programmatically, this naming can be integrated into the code.

Or if you know where the charts are in the sheet, you can loop through the
chart objects to find the one whose .TopLeftCell is a particular cell.

- Jon
-------
Jon Peltier, Microsoft Excel MVP
Peltier Technical Services, Inc.
http://PeltierTech.com/WordPress/
_______


"Tom" wrote in message
...
I have a number of charts in my worksheet that I would like to copy to a
word
document. I am thinking the best way is to:

1. select the chart object
2. copy it
3. Tthen open a Word doc (not sure about the code for this)
4. paste it in the word doc

How can I get the chart object number to select the chart? for example if
I
have 200 charts they are not always numbered sequentially from 1-200
depending on how many times the charts are created. I may have a chart
299,
then a chart 333. How do I go the chart object number to be able to
reference it and select the chart.



  #3   Report Post  
Posted to microsoft.public.excel.charting
tom tom is offline
external usenet poster
 
Posts: 570
Default Chart object number

Jon,

Thanks. I will try to programmatically rename them. Is there a way to
determine the index number for each chart and then use that?

Thanks
Tom


"Jon Peltier" wrote:

You could manually or programmatically rename the chart objects
(http://peltiertech.com/Excel/ChartsH...meAChart.html). If the charts
are created programmatically, this naming can be integrated into the code.

Or if you know where the charts are in the sheet, you can loop through the
chart objects to find the one whose .TopLeftCell is a particular cell.

- Jon
-------
Jon Peltier, Microsoft Excel MVP
Peltier Technical Services, Inc.
http://PeltierTech.com/WordPress/
_______


"Tom" wrote in message
...
I have a number of charts in my worksheet that I would like to copy to a
word
document. I am thinking the best way is to:

1. select the chart object
2. copy it
3. Tthen open a Word doc (not sure about the code for this)
4. paste it in the word doc

How can I get the chart object number to select the chart? for example if
I
have 200 charts they are not always numbered sequentially from 1-200
depending on how many times the charts are created. I may have a chart
299,
then a chart 333. How do I go the chart object number to be able to
reference it and select the chart.




  #4   Report Post  
Posted to microsoft.public.excel.charting
external usenet poster
 
Posts: 6,582
Default Chart object number

If you don't care which ones are accessed in which order, you could use
this:

For iChart = 1 To ActiveSheet.ChartObjects.Count
With ActiveSheet.ChartObjects(iChart)
' do your stuff
End With
Next

- Jon
-------
Jon Peltier, Microsoft Excel MVP
Peltier Technical Services, Inc.
http://PeltierTech.com/WordPress/
_______


"Tom" wrote in message
...
Jon,

Thanks. I will try to programmatically rename them. Is there a way to
determine the index number for each chart and then use that?

Thanks
Tom


"Jon Peltier" wrote:

You could manually or programmatically rename the chart objects
(http://peltiertech.com/Excel/ChartsH...meAChart.html). If the charts
are created programmatically, this naming can be integrated into the
code.

Or if you know where the charts are in the sheet, you can loop through
the
chart objects to find the one whose .TopLeftCell is a particular cell.

- Jon
-------
Jon Peltier, Microsoft Excel MVP
Peltier Technical Services, Inc.
http://PeltierTech.com/WordPress/
_______


"Tom" wrote in message
...
I have a number of charts in my worksheet that I would like to copy to a
word
document. I am thinking the best way is to:

1. select the chart object
2. copy it
3. Tthen open a Word doc (not sure about the code for this)
4. paste it in the word doc

How can I get the chart object number to select the chart? for example
if
I
have 200 charts they are not always numbered sequentially from 1-200
depending on how many times the charts are created. I may have a chart
299,
then a chart 333. How do I go the chart object number to be able to
reference it and select the chart.






Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do i export a pivot chart as a static chart object? James Charts and Charting in Excel 2 November 11th 08 10:05 PM
Naming a chart object Jeff M Charts and Charting in Excel 6 September 23rd 08 06:00 AM
Chart Object VB Code MS[_2_] Charts and Charting in Excel 2 March 6th 07 11:41 AM
Modifying a Chart Object Name pauloreiss Excel Discussion (Misc queries) 0 December 21st 05 05:43 PM
How do I name a chart as an identifiable object? confused Charts and Charting in Excel 3 August 16th 05 05:12 PM


All times are GMT +1. The time now is 12:05 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"