automatically selecting cell ranges for a chart
Posted by Eddie Adams on January 02, 2002 5:56 PM
I was looking for some info on Excel that can help solve a little problem I have and hope you can help.
I have written a program that transfers some data into an Excel file with pre-existing charts. The number of columns that comprise each chart is fixed; however, the number of rows can change considerably. Therefore, I'm trying to find a way to expand or contract the range of cells for a chart (depending on the number of data rows) without the user having to do anything. Maybe I can invoke a macro or something, but I don't know much about them or how to send a variable to the macro (i.e., a variable indicating as cell range) for it to use. I'm trying to do this because new data will be exported into this Excel file many times and on daily basis, and I don't want the user to have to mess with the cell ranges that comprise the chart. Any help?
Thanks in advance!