PC Review


Reply
Thread Tools Rate Thread

Can I format data lines in multiple charts?

 
 
=?Utf-8?B?Y29sbGVlbjkxMDc2?=
Guest
Posts: n/a
 
      7th Oct 2005
Can I format a data series in multiple charts without doing it individually?
For example: I have a woorkbook with 50 charts, and each has the same X/Y
axes, and each chart has multiple lines for 1999, 2000, 2001, 2002, etc. Can
I format one data series, i.e. year 1999 in Chart A and have Excel
auto-format all other 1999 series (charts B-Z) to match it?
 
Reply With Quote
 
 
 
 
Andy Pope
Guest
Posts: n/a
 
      7th Oct 2005
Hi,

The closet thing you will get without resorting to VBA code is the F4
button. Format 1999 series in one chart and then select it in another
chart and press F4. Trouble is thats still 49 selections and then repeat
that for each of the years!

Here is the start of a macro. This will turn the first data series in
all charts on the activesheet red, or what ever colour you have mapped
in colorindex 3.
Turn on the recorder whilst you format a line and see if you can insert
you code in to this example.

Sub Macro1()
'
' Macro1 Macro
' Macro recorded 10/7/2005 by Andy Pope
'
Dim objCht As ChartObject
'
For Each objCht In ActiveSheet.ChartObjects
With objCht.Chart
With .SeriesCollection(1)
With .Border
.ColorIndex = 3
.Weight = xlThin
.LineStyle = xlContinuous
End With
.MarkerBackgroundColorIndex = 3
.MarkerForegroundColorIndex = 3
.MarkerStyle = xlDiamond
.Smooth = False
.MarkerSize = 5
.Shadow = False
End With
End With
Next
End Sub

Cheers
Andy

colleen91076 wrote:
> Can I format a data series in multiple charts without doing it individually?
> For example: I have a woorkbook with 50 charts, and each has the same X/Y
> axes, and each chart has multiple lines for 1999, 2000, 2001, 2002, etc. Can
> I format one data series, i.e. year 1999 in Chart A and have Excel
> auto-format all other 1999 series (charts B-Z) to match it?


--

Andy Pope, Microsoft MVP - Excel
http://www.andypope.info
 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Charts - Data Format A97 Kahuna Microsoft Access Form Coding 4 22nd Feb 2007 09:02 AM
data table - lines variables for DB functions, charts.. etc.. Marina Limeira Microsoft Excel Misc 0 20th Jan 2006 10:20 PM
Change colour of bars/lines in charts when data in rows/colums =?Utf-8?B?Um9kUA==?= Microsoft Excel Programming 10 27th Oct 2005 05:07 PM
Format multiple Charts =?Utf-8?B?YWRvZHNvbg==?= Microsoft Excel Charting 1 26th Aug 2005 07:58 PM
conditional format of data tables in charts daniel.finnigan@redcats.co.uk Microsoft Excel Charting 2 25th Jan 2005 03:56 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 04:20 PM.