I'm fairly new to Visual Basic, so the answer to this might be really simple...(adsbygoogle = window.adsbygoogle || []).push({});

So here's the deal:

I have something like 500 Excel worksheets, that each contain the following:

1. 2-N equally long rows of data

2. A Line graph of one of rows 2-N versus the top row

What I need to do is change the line color in the graph, according to the numerical value of each data point. Needless to say, since there are hundreds of these graphs, I'd like to be able to write a macro that will do this for me.

My problem is, the data row that is plotted against the top row varies from sheet to sheet, which means I don't know which row to look at when deciding the color. Is there any way to obtain this information from the Chart object?

Any help would really be appreciated, I'm starting to think I could've done this manually in the time it's taken me to write the macro :)

Thanks in advance!

**Physics Forums | Science Articles, Homework Help, Discussion**

Join Physics Forums Today!

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

# Any VBA / Excel gurus present?

**Physics Forums | Science Articles, Homework Help, Discussion**