ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Changeing a graph (https://www.excelbanter.com/excel-programming/290967-changeing-graph.html)

Mark Scholes

Changeing a graph
 
Hi,
I want to change a graph dynamicly, so it will graph only
the range of value I which it too.

Sheets("Graph Book").Select
Charts("Chart 1").SeriesCollection(1).XValues = Sheets
("Graph Data").Range("B1:IU1")

This give a subscript out of range error, how do I fix it.

Thanks MarkS

Tom Ogilvy

Changeing a graph
 
Subscript out of range means one of the names you have in your code does not
exist. Example, you don't have a Chart 1 (maybe you have a Chart1 or it
is no longer named chart 1. )

--
Regards,
Tom Ogilvy



Mark Scholes wrote in message
...
Hi,
I want to change a graph dynamicly, so it will graph only
the range of value I which it too.

Sheets("Graph Book").Select
Charts("Chart 1").SeriesCollection(1).XValues = Sheets
("Graph Data").Range("B1:IU1")

This give a subscript out of range error, how do I fix it.

Thanks MarkS





All times are GMT +1. The time now is 02:43 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com