fabiospark
New Member
- Joined
- May 29, 2015
- Messages
- 13
Let me explain.
I have a few identically structured sheets with different names: LM1 LM2 LM3 etc.
In each of them there is an identically structured chart where the sources for its 10 series are defined
by 10 dynamic sheet level named ranges with OFFSET functions who refers to both sheet LM1 and LM1sto.
By now I created the named range for the first series of the first sheet in this shape [=OFFSET(LM1sto!$B$8;0;;COUNTIF(LM1sto!$FG:$FG;">0")
where only the range into the countif ($FG:$FG) will be different for each series.
Then, with VBA I created the names for each of the other sheets changing just the sheet name.
Then I started to think if it would be possible to define these names using INDIRECT to get all the sheet related info from some cells into the sheet itself
so I would be able to use only 10 worbook level names instead of 100 sheet level names. This is what I mean:
LM1!Ch_TRPF = OFFSET(INDIRECT($I$1&"sto!$B$8");$J$29;;$K$29-$J$29+1)
where:
LM1!Ch_TRPF = Name of the range that holds the values
$I$1 = LM1 (sheet name)
$JK$29 = index value for the starting date of the data set to show
$K$29 = index value for the ending date of the data set
$K$29-J$29+1 = numbers of row of the dataset between starting and ending dates
Do you think I could use Ch_TRPF as a workbook level name for all the sheet and it will
pick up the values from the sheet the chart is on to?
If not directly, is there an inderect way (VBA)?
Hope I made myself clear.
Thanks.
I have a few identically structured sheets with different names: LM1 LM2 LM3 etc.
In each of them there is an identically structured chart where the sources for its 10 series are defined
by 10 dynamic sheet level named ranges with OFFSET functions who refers to both sheet LM1 and LM1sto.
By now I created the named range for the first series of the first sheet in this shape [=OFFSET(LM1sto!$B$8;0;;COUNTIF(LM1sto!$FG:$FG;">0")
where only the range into the countif ($FG:$FG) will be different for each series.
Then, with VBA I created the names for each of the other sheets changing just the sheet name.
Then I started to think if it would be possible to define these names using INDIRECT to get all the sheet related info from some cells into the sheet itself
so I would be able to use only 10 worbook level names instead of 100 sheet level names. This is what I mean:
LM1!Ch_TRPF = OFFSET(INDIRECT($I$1&"sto!$B$8");$J$29;;$K$29-$J$29+1)
where:
LM1!Ch_TRPF = Name of the range that holds the values
$I$1 = LM1 (sheet name)
$JK$29 = index value for the starting date of the data set to show
$K$29 = index value for the ending date of the data set
$K$29-J$29+1 = numbers of row of the dataset between starting and ending dates
Do you think I could use Ch_TRPF as a workbook level name for all the sheet and it will
pick up the values from the sheet the chart is on to?
If not directly, is there an inderect way (VBA)?
Hope I made myself clear.
Thanks.