ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   create a chart without set range (https://www.excelbanter.com/excel-programming/340897-create-chart-without-set-range.html)

Noemi

create a chart without set range
 
I have a 2 columns of data which can vary in length.

Is it possible to create a chart where you only have the start range but not
an end range.

Example:

1 5
2 1
3 6
5 1
23 8
45 4

I want to produce a chart where it show goes to the first column (1) and
then uses the code range(selection, selection.end(xlDown)).select uses the
range that is highlighted as the x axis and then do the same thing for the
second column (5) as Y axis.

This is required as we do not know how many lines of data there will be each
time we create a new chart as we wont the chart to be created by using a
button rather than manually doing it each time.

I hope this makes sense and someone can help.

Thanks
Noemi

R.VENKATARAMAN

create a chart without set range
 
see pages of Peltier and tushar Mehta - on dynamic ranges.


"Noemi" wrote in message
...
I have a 2 columns of data which can vary in length.

Is it possible to create a chart where you only have the start range but

not
an end range.

Example:

1 5
2 1
3 6
5 1
23 8
45 4

I want to produce a chart where it show goes to the first column (1) and
then uses the code range(selection, selection.end(xlDown)).select uses the
range that is highlighted as the x axis and then do the same thing for the
second column (5) as Y axis.

This is required as we do not know how many lines of data there will be

each
time we create a new chart as we wont the chart to be created by using a
button rather than manually doing it each time.

I hope this makes sense and someone can help.

Thanks
Noemi




Tushar Mehta

create a chart without set range
 
In my case, specifically
Dynamic Charts
http://www.tushar-mehta.com/excel/ne...rts/index.html
--
Regards,

Tushar Mehta
www.tushar-mehta.com
Excel, PowerPoint, and VBA add-ins, tutorials
Custom MS Office productivity solutions

In article ,
says...
see pages of Peltier and tushar Mehta - on dynamic ranges.


{snip}

Noemi

create a chart without set range
 
Hi Tushar
Can you please confirm if I am meant to replace the set ranges with the 2
formula's that have to do with adding additional data.

I seem to be having trouble understanding what and where I am to place the
code plus it doesn't seem to like it in my code.

Thank you for your help.
Noemi

"Tushar Mehta" wrote:

In my case, specifically
Dynamic Charts
http://www.tushar-mehta.com/excel/ne...rts/index.html
--
Regards,

Tushar Mehta
www.tushar-mehta.com
Excel, PowerPoint, and VBA add-ins, tutorials
Custom MS Office productivity solutions

In article ,
says...
see pages of Peltier and tushar Mehta - on dynamic ranges.


{snip}


Tushar Mehta

create a chart without set range
 
The solution doesn't require any VBA code; it relies on named formulas.

If you want the code to create the named formulas, turn on the macro
recorder (Tools | Macro Record new macro...), create the names as
shown in the web page, and turn off the recorder. XL will give you the
necessary code.

--
Regards,

Tushar Mehta
www.tushar-mehta.com
Excel, PowerPoint, and VBA add-ins, tutorials
Custom MS Office productivity solutions

In article ,
says...
Hi Tushar
Can you please confirm if I am meant to replace the set ranges with the 2
formula's that have to do with adding additional data.

I seem to be having trouble understanding what and where I am to place the
code plus it doesn't seem to like it in my code.

Thank you for your help.
Noemi

"Tushar Mehta" wrote:

In my case, specifically
Dynamic Charts
http://www.tushar-mehta.com/excel/ne...rts/index.html
--
Regards,

Tushar Mehta
www.tushar-mehta.com
Excel, PowerPoint, and VBA add-ins, tutorials
Custom MS Office productivity solutions

In article ,
says...
see pages of Peltier and tushar Mehta - on dynamic ranges.


{snip}




All times are GMT +1. The time now is 05:22 PM.

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