LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 504
Default TypeName:="Line - Stacked Column on 2 Axes" ???

The following code works well. I've been asked to show the two columns as
stacked. Is this something that be programmed? Thanks.

Kevin


Sub TestChart()
Dim Series1Rng As Range
Dim Series2Rng As Range
Dim Series3Rng As Range
Dim SeriesXValuesRng As Range
DeleteCharts
strSheetName$ = "Charts"
Set SeriesXValuesRng = Worksheets(strSheetName$).Range("A2:A4")
Set Series1Rng = Worksheets(strSheetName$).Range("B2:B4")
Set Series2Rng = Worksheets(strSheetName$).Range("C2:C4")
Set Series3Rng = Worksheets(strSheetName$).Range("D2:D4")
With ActiveSheet.ChartObjects.Add _
(Left:=100, Width:=600, Top:=100, Height:=200)
With .Chart.SeriesCollection.NewSeries
.Values = Series1Rng
.XValues = SeriesXValuesRng
End With
With .Chart.SeriesCollection.NewSeries
.Values = Series2Rng
End With
With .Chart.SeriesCollection.NewSeries
.Values = Series3Rng
End With
.Chart.ApplyCustomType ChartType:=xlBuiltIn, TypeName:="Line -
Column on 2 Axes"
.Chart.Location Whe=xlLocationAsObject, Name:=strSheetName$
.Chart.HasLegend = False
End With
Sheets(strSheetName$).Range("E1").Select
End Sub

'Data:
'1 A B C D
'2 Jul-08 2768 1094 144204
'3 Aug-08 2627 1022 153008
'4 Sep-08 5348 1244 197267
 
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 can i get a "Column - Line on 2 axes" graph? bunjoy Charts and Charting in Excel 1 September 28th 07 02:22 PM
Chart: "Line-Column on 2 Axes"... but... (PeteCresswell) Excel Programming 3 January 31st 07 02:54 PM
How do you select line or columns in "Line-Column on 2 axes" graphs? mizterbusy Excel Discussion (Misc queries) 0 September 19th 06 06:48 AM
How to apply the custom chart type: "Line - Column on 2 Axes" talrs Excel Programming 0 April 20th 06 09:23 AM
Line Column on 2 axes that shows stacked colums Paul Henderson Charts and Charting in Excel 2 February 27th 05 02:22 PM


All times are GMT +1. The time now is 09:01 AM.

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

About Us

"It's about Microsoft Excel"