I am creating a bar stacked bar chart. I send over data from access and open up excel thru automation. I have created a macro that creates this chart ... however,
the macro HARDCODES the initial data range. When I send over new data (with more rows), the macro, of course, only selects the previous datarange I sent.
Can anyone help me with code that I could use that would allow for a variable data range to be input into the "SETSOURCEDATA" line of my macro?
Thanks!!
(e.g. data)
Indication Offset Duration
Ind_1 2 5
Ind_2 4 5
Ind_3 6 9
(Above cells DATARANGE a1:c3
Indication Offset Duration
Ind_1 2 5
Ind_2 4 5
Ind_3 6 9
Ind_4 7 2
Ind_5 8 7
Ind_6 9 4
(When I send THIS data over, my macro still only uses the previous A1:C3 range!!!!
THANKS!!!
This message was edited by jamesgw on 2002-05-10 11:20
This message was edited by jamesgw on 2002-05-10 11:22
the macro HARDCODES the initial data range. When I send over new data (with more rows), the macro, of course, only selects the previous datarange I sent.
Can anyone help me with code that I could use that would allow for a variable data range to be input into the "SETSOURCEDATA" line of my macro?
Thanks!!
(e.g. data)
Indication Offset Duration
Ind_1 2 5
Ind_2 4 5
Ind_3 6 9
(Above cells DATARANGE a1:c3
Indication Offset Duration
Ind_1 2 5
Ind_2 4 5
Ind_3 6 9
Ind_4 7 2
Ind_5 8 7
Ind_6 9 4
(When I send THIS data over, my macro still only uses the previous A1:C3 range!!!!
THANKS!!!
This message was edited by jamesgw on 2002-05-10 11:20
This message was edited by jamesgw on 2002-05-10 11:22