Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
As far as I can tell, this *should* embed my chart in the Active worksheet:
xlapp.Workbooks(strXlsFile).ActiveChart.Location Whe= _ xlLocationAsObject, Name:=strSheetName (where strSheetName is the name of the target worksheet) But when I put this code in a loop, the chart is created in it's *own sheet*: xlapp.Workbooks(strXlsFile).Charts.Add.Name = strSheetName xlapp.Workbooks(strXlsFile).ActiveChart.SetSourceD ata Source:= _ xlapp.Workbooks(strXlsFile).Worksheets(j + 1).Range("A1:C" & _ xlapp.Workbooks(strXlsFile).Worksheets(j + 1).Range("C1").End(xlDown).Row), PlotBy:=xlColumns xlapp.Workbooks(strXlsFile).ActiveChart.Axes(xlCat egory, xlPrimary).HasTitle = False xlapp.Workbooks(strXlsFile).ActiveChart.Axes(xlVal ue, xlPrimary).HasTitle = False xlapp.Workbooks(strXlsFile).ActiveChart.HasLegend = False xlapp.Workbooks(strXlsFile).ActiveChart.HasTitle = False Am I missing something obvious, or do I need to do something different when using automation? Thanks in advance. |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
can you embed a worksheet within the cell of another worksheet? | Excel Worksheet Functions | |||
How to embed expression in data labels on a chart | Charts and Charting in Excel | |||
how do I embed files to tabs in a worksheet? | Excel Discussion (Misc queries) | |||
Embed Picture of Chart | Charts and Charting in Excel | |||
Why can't I embed a button on a chart in Excel 2003? | Charts and Charting in Excel |