From: Mike on
The problem I'm having is that I am trying to change the color of one of my series in an excel chart that I have plotted as a xlXYScatterSmooth. To clarify I want the color of the LINE to be changed and not the markers~

so I know that the macro that VB produces gives

ActiveChart.SeriesCollection(9).Select
With Selection.Border
.ColorIndex = 1
.Weight = xlThick
.LineStyle = xlContinuous
End With

But I can't just do:

..SeriesCollection(9).Border.ColorIndex = 1

as that does not work

Not really sure on what to do to get the color to change~

Thanks
From: Yair Altman on
> But I can't just do:
>
> .SeriesCollection(9).Border.ColorIndex = 1
>
> as that does not work

..SeriesCollection.Item(9).Border.ColorIndex = 1

Yair Altman
http://UndocumentedMatlab.com
From: Mike on
"Yair Altman" <altmanyDEL(a)gmailDEL.comDEL> wrote in message <i1ngp2$4ma$1(a)fred.mathworks.com>...
> > But I can't just do:
> >
> > .SeriesCollection(9).Border.ColorIndex = 1
> >
> > as that does not work
>
> .SeriesCollection.Item(9).Border.ColorIndex = 1
>
> Yair Altman
> http://UndocumentedMatlab.com

Omg, ty so much :D
From: Mike on
"Mike " <mike87y(a)gmail.com> wrote in message <i1nhs4$evj$1(a)fred.mathworks.com>...
> "Yair Altman" <altmanyDEL(a)gmailDEL.comDEL> wrote in message <i1ngp2$4ma$1(a)fred.mathworks.com>...
> > > But I can't just do:
> > >
> > > .SeriesCollection(9).Border.ColorIndex = 1
> > >
> > > as that does not work
> >
> > .SeriesCollection.Item(9).Border.ColorIndex = 1
> >
> > Yair Altman
> > http://UndocumentedMatlab.com
>
> Omg, ty so much :D

I've realized that this works in Excel 2003, however when I try to do it in Excel 2007 it says it is not an appropriate method/property
From: Mike on
"Mike " <mike87y(a)gmail.com> wrote in message <i1nhs4$evj$1(a)fred.mathworks.com>...
> "Yair Altman" <altmanyDEL(a)gmailDEL.comDEL> wrote in message <i1ngp2$4ma$1(a)fred.mathworks.com>...
> > > But I can't just do:
> > >
> > > .SeriesCollection(9).Border.ColorIndex = 1
> > >
> > > as that does not work
> >
> > .SeriesCollection.Item(9).Border.ColorIndex = 1
> >
> > Yair Altman
> > http://UndocumentedMatlab.com
>
> Omg, ty so much :D

I've realized that this works in Excel 2003, however when I try to do it in Excel 2007 it says it is not an appropriate method/property