Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have a number of tables in a worksheet and need to generate a standard
graph beside each one. I can generate the graphs OK but my problem is by default they always appear in the middle of the current view and are the wrong size. My ideal solution would be to be able to control where the chart first appears, and what its dimensions are, when it is created. Is there anyway to do this? (I'm currently using Charts.Add ActiveChart.Location Whe=xlLocationAsObject, Name:="Sheet1" in order to create the chart.) At the moment, I am resizing each chart using the Shapes method, but first I have to find out the name: Dim ref As Variant ref = Right(ActiveChart.Name, Len(ActiveChart.Name) - Len(ActiveSheet.Name & " ")) ActiveSheet.Shapes(ref).ScaleHeight 0.6, msoFalse ActiveSheet.Shapes(ref).ScaleWidth 1.2, msoFalse The definition of "ref" is rather forced since ActiveChart.Name returns a string such as "Sheet1 Chart 215" not the "Chart 215" bit, which is what Shapes needs. I can't believe there isn't a more efficient way to do this. Any suggestions? Thanks |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Name Embedded Chart | Excel Worksheet Functions | |||
Embedded Table in Chart | Excel Discussion (Misc queries) | |||
Embedded Chart Versus Chart - ShowDetail Issue | Charts and Charting in Excel | |||
enabling chart events for an embedded chart | Excel Programming | |||
what is the difference between embedded chart and chart-in-a-sheet | Excel Programming |