View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
Jon Peltier Jon Peltier is offline
external usenet poster
 
Posts: 6,582
Default Chart or Shape Object: A Place To Stash A Few Bytes?

Actually, to me it sounded like a fine idea to create and position the chart
all at once. In fact, using mySheet.ChartObjects.Add() does both at once;
check the documentation or look for it he

http://peltiertech.com/Excel/ChartsH...kChartVBA.html

- Jon
-------
Jon Peltier, Microsoft Excel MVP
Tutorials and Custom Solutions
http://PeltierTech.com
_______


"(PeteCresswell)" wrote in message
...
Per Jon Peltier:
I think PowerPoint shapes have this, but Excel shapes do not. However, you
could add an invisible textbox to a chart:

activechart.Shapes.AddTextbox(msoTextOrientation Horizontal,0,0,100,15).Name
= "MyTag"
activechart.Shapes("MyTag").TextFrame.Characters .Text="$R05$C13:$R45$C22"
activechart.Shapes("MyTag").Visible=false
?activechart.Shapes("MyTag").TextFrame.Character s.Text
$R05$C13:$R45$C22


Thanks. That will definitely do it. I'll hold off on merging the chart
creation/positioning processes and give that a shot.
--
PeteCresswell