rianz
05-23-2011, 08:06 PM
Hi, im new using vba excel and im using excel 2007.
im create chart using recording macro and here my code:
Private Sub CommandButton1_Click()
ActiveSheet.Shapes.AddChart.Select
ActiveChart.SetSourceData Source:=Range( _
"'siklus'!$B$2:$B$2709,'siklus'!$C$2:$C$2709,'siklus'!$U$2:$U$2709")
ActiveChart.ChartType = xlLine
ActiveSheet.Shapes.AddChart.Select
ActiveChart.SetSourceData Source:=Range( _
"'siklus'!$B$2:$B$2709,'siklus'!$D$2:$D$2709,'siklus'!$U$2:$U$2709")
ActiveChart.ChartType = xlLine
.
.
.
ActiveSheet.Shapes.AddChart.Select
ActiveChart.SetSourceData Source:=Range( _
"'siklus'!$B$2:$B$2709,'siklus'!$T$2:$T$2709,'siklus'!$U$2:$U$2709")
ActiveChart.ChartType = xlLine
End Sub
my question is how to coloring data series,change legend position to bottom.
thx
*Sorry for my bad english...
im create chart using recording macro and here my code:
Private Sub CommandButton1_Click()
ActiveSheet.Shapes.AddChart.Select
ActiveChart.SetSourceData Source:=Range( _
"'siklus'!$B$2:$B$2709,'siklus'!$C$2:$C$2709,'siklus'!$U$2:$U$2709")
ActiveChart.ChartType = xlLine
ActiveSheet.Shapes.AddChart.Select
ActiveChart.SetSourceData Source:=Range( _
"'siklus'!$B$2:$B$2709,'siklus'!$D$2:$D$2709,'siklus'!$U$2:$U$2709")
ActiveChart.ChartType = xlLine
.
.
.
ActiveSheet.Shapes.AddChart.Select
ActiveChart.SetSourceData Source:=Range( _
"'siklus'!$B$2:$B$2709,'siklus'!$T$2:$T$2709,'siklus'!$U$2:$U$2709")
ActiveChart.ChartType = xlLine
End Sub
my question is how to coloring data series,change legend position to bottom.
thx
*Sorry for my bad english...