If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
HELP REF. NEW DATA ONLY AS i MOVE TO ANY CELL IN THE NEW ROW/RANGE
I need a macrocode to change the data range in an inbeded chart as I move to any cell in the new row/range. this will be for the same type of data from a specific range of rows. If you can help, I would be most grateful! I am an experienced Excel
user, but only a beginner VBA code writer. I feel it will take me a while to learn the code development well enough and I am on a time constraint. Thanks, Areidski |
#2
|
|||
|
|||
No need for VBA code. Can be done by leveraging a little known fact of
named ranges using relative references. Suppose your data are in A:C with A as the series name and B as the x value and C as the y value. Suppose your data start in row 2. With any cell in row 2 selected, create three names: SerName =Sheet2!$A2 XVal =Sheet2!$B2 YVal =Sheet2!$C2+NOW()*0 Create a chart. Use the named formula for the various data sources. For an intro see 'Names in Charts' http://www.tushar- mehta.com/excel/newsgroups/dynamic_charts/names_in_charts.html When done, the series formula should look like: =SERIES('relative name in chart.xls'!SerName,'relative name in chart.xls'!XVal,'relative name in chart.xls'!YVal,1) where 'relative name in chart.xls' is the name of your workbook. Now, select any cell in a different row (say, row 3) and press F9. The chart will show the information from that row. -- Regards, Tushar Mehta www.tushar-mehta.com Excel, PowerPoint, and VBA add-ins, tutorials Custom MS Office productivity solutions In article , says... I need a macrocode to change the data range in an inbeded chart as I move to any cell in the new row/range. this will be for the same type of data from a specific range of rows. If you can help, I would be most grateful! I am an experienced Excel user, but only a beginner VBA code writer. I feel it will take me a while to learn the code development well enough and I am on a time constraint. Thanks, Areidski |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Possible Lookup Table | Karen | Worksheet Functions | 5 | June 8th, 2005 09:43 PM |
Sort pages? | David | General Discussion | 15 | May 13th, 2005 11:33 PM |
Format on data to import to Access tables? (I need your advice) | Niklas Östergren | General Discussion | 5 | December 13th, 2004 02:54 PM |
Move data from one column to another | Frank Kabel | Worksheet Functions | 5 | March 17th, 2004 01:21 AM |
Cell reference data not displaying in chart | Jon Peltier | Charts and Charting | 0 | November 12th, 2003 06:30 PM |