Chart with Dynamic Ranges

zinah

Active Member
Joined
Nov 28, 2018
Messages
353
Office Version
  1. 365
Platform
  1. Windows
Hello,

I was trying to paste a mini sheet here but got error message (as showing in screenshot attached). I have a drop-down list that can pull different data, some data has blanks or 0s. What I need to create is dynamic ranges for this data to be presented in a chart (like bar chart or column chart). Can anyone help?

Dropdown list that has all Top Leader Names
DEF
Manager NameJan-2023Feb-2023Mar-2023Apr-2023May-2023Jun-2023Jul-2023Aug-2023Sep-2023Oct-2023Nov-2023Dec-2023Jan-2024May-2024Jun-2024Dec-2024Aug-2025
BB1
AA2111
CC1
DD97
EE1
FF
GG1121
HH13
RR921115612
YY111
20512132111501600132


Thank you,
Zina
 

Excel Facts

Which lookup functions find a value equal or greater than the lookup value?
MATCH uses -1 to find larger value (lookup table must be sorted ZA). XLOOKUP uses 1 to find values greater and does not need to be sorted.
What is the relationship of the Top Leader Names to the data?
Is there other data that goes into the reporting?
 
Upvote 0
What is the relationship of the Top Leader Names to the data?
Is there other data that goes into the reporting?
The numbers of each month and leaders names are dynamic, whenever I change the leader name, the manager name will change and numbers of each month will change too.
 
Upvote 0
The numbers of each month and leaders names are dynamic, whenever I change the leader name, the manager name will change and numbers of each month will change too.
Do you have sample (anonymized) data?
 
Upvote 0
Do you have sample (anonymized) data?
Yes, here's the sample data:

Dynamic Ranges Chart.xlsx
ABCDEFGHIJKLMNOPQR
1Dropdown list that has all Top Leader Names
2DEF
3
4
5Manager NameJan-2023Feb-2023Mar-2023Apr-2023May-2023Jun-2023Jul-2023Aug-2023Sep-2023Oct-2023Nov-2023Dec-2023Jan-2024May-2024Jun-2024Dec-2024Aug-2025
6BB1
7AA2111
8CC1
9DD97
10EE1
11FF
12GG1121
13HH13
14RR921115612
15YY111
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
3220512132111501600132
Sheet1
Cell Formulas
RangeFormula
B32:R32B32=SUM(B6:B31)
Cells with Data Validation
CellAllowCriteria
A2ListABC, DEF, REE, ZNA
 
Upvote 0
Please get the xl2BB tool. It took me quite a while to build a sample data set. I don't think the chart above is your source data (My sample data are in A20:C109). But, please let me know if this works for you? It can be made more elegantly with Let and Lambda functions.
WorkBook1.xlsx
ABCDEFGH
1Dropdown list that has all Top Leader NamesLEADER
2DEFABC
3DEF
4Manager NameJan-23Feb-23Mar-23REE
5BB012ZNA
6AA200
7CC000
8DD001
9EE002
10FF000
11GG000
12HH100
13RR000
14YY000
15
16
17
18
19DATELEADERMANAGER
201/1/2023ABCAA
211/2/2023DEFAA
221/3/2023REEAA
231/4/2023ZNACC
241/5/2023ABCBB
251/6/2023DEFAA
261/7/2023REEDD
271/8/2023ZNAFF
281/9/2023ABCBB
291/10/2023DEF
301/11/2023REE
311/12/2023ZNABB
321/13/2023ABCYY
331/14/2023DEF
341/15/2023REE
351/16/2023ZNA
361/17/2023ABC
371/18/2023DEFHH
381/19/2023REE
391/20/2023ZNA
401/21/2023ABC
411/22/2023DEF
421/23/2023REEHH
431/24/2023ZNA
441/25/2023ABC
451/26/2023DEF
461/27/2023REE
471/28/2023ZNAHH
481/29/2023ABC
491/30/2023DEF
501/31/2023REE
512/1/2023ZNA
522/2/2023ABC
532/3/2023DEF
542/4/2023REE
552/5/2023ZNA
562/6/2023ABCDD
572/7/2023DEF
582/8/2023REEAA
592/9/2023ZNA
602/10/2023ABCAA
612/11/2023DEF
622/12/2023REEHH
632/13/2023ZNA
642/14/2023ABCAA
652/15/2023DEFBB
662/16/2023REE
672/17/2023ZNA
682/18/2023ABCBB
692/19/2023DEF
702/20/2023REEAA
712/21/2023ZNA
722/22/2023ABCYY
732/23/2023DEF
742/24/2023REECC
752/25/2023ZNA
762/26/2023ABC
772/27/2023DEF
782/28/2023REEFF
793/1/2023ZNA
803/2/2023ABC
813/3/2023DEF
823/4/2023REE
833/5/2023ZNAFF
843/6/2023ABC
853/7/2023DEF
863/8/2023REE
873/9/2023ZNAAA
883/10/2023ABC
893/11/2023DEF
903/12/2023REEBB
913/13/2023ZNA
923/14/2023ABC
933/15/2023DEFBB
943/16/2023REEEE
953/17/2023ZNAEE
963/18/2023ABCEE
973/19/2023DEFEE
983/20/2023REEEE
993/21/2023ZNAEE
1003/22/2023ABCEE
1013/23/2023DEFEE
1023/24/2023REEDD
1033/25/2023ZNAGG
1043/26/2023ABCRR
1053/27/2023DEFDD
1063/28/2023REECC
1073/29/2023ZNAYY
1083/30/2023ABCYY
1093/31/2023DEFBB
110
Sheet1
Cell Formulas
RangeFormula
B4:D4B4=DATE(2023,SEQUENCE(1,3,1,1),1)
B5:C14B5=SUMPRODUCT(--(Sheet1!$A$20:$A$109<=EOMONTH(B$4,0))* --(Sheet1!$A$20:$A$109>=B$4)* --($A$2 = Sheet1!$B$20:$B$109)*--($A5=Sheet1!$C$20:$C$109))
D5:D14D5=SUMPRODUCT( --(Sheet1!$A$20:$A$109>=D$4), --(Sheet1!$A$20:$A$109<=EOMONTH(D$4,0)), --($A$2 = Sheet1!$B$20:$B$109), --($A5=Sheet1!$C$20:$C$109))
Dynamic array formulas.
Cells with Data Validation
CellAllowCriteria
A2:A3List=$G$2:$G$5
 
Upvote 0
Please get the xl2BB tool. It took me quite a while to build a sample data set. I don't think the chart above is your source data (My sample data are in A20:C109). But, please let me know if this works for you? It can be made more elegantly with Let and Lambda functions.
WorkBook1.xlsx
ABCDEFGH
1Dropdown list that has all Top Leader NamesLEADER
2DEFABC
3DEF
4Manager NameJan-23Feb-23Mar-23REE
5BB012ZNA
6AA200
7CC000
8DD001
9EE002
10FF000
11GG000
12HH100
13RR000
14YY000
15
16
17
18
19DATELEADERMANAGER
201/1/2023ABCAA
211/2/2023DEFAA
221/3/2023REEAA
231/4/2023ZNACC
241/5/2023ABCBB
251/6/2023DEFAA
261/7/2023REEDD
271/8/2023ZNAFF
281/9/2023ABCBB
291/10/2023DEF
301/11/2023REE
311/12/2023ZNABB
321/13/2023ABCYY
331/14/2023DEF
341/15/2023REE
351/16/2023ZNA
361/17/2023ABC
371/18/2023DEFHH
381/19/2023REE
391/20/2023ZNA
401/21/2023ABC
411/22/2023DEF
421/23/2023REEHH
431/24/2023ZNA
441/25/2023ABC
451/26/2023DEF
461/27/2023REE
471/28/2023ZNAHH
481/29/2023ABC
491/30/2023DEF
501/31/2023REE
512/1/2023ZNA
522/2/2023ABC
532/3/2023DEF
542/4/2023REE
552/5/2023ZNA
562/6/2023ABCDD
572/7/2023DEF
582/8/2023REEAA
592/9/2023ZNA
602/10/2023ABCAA
612/11/2023DEF
622/12/2023REEHH
632/13/2023ZNA
642/14/2023ABCAA
652/15/2023DEFBB
662/16/2023REE
672/17/2023ZNA
682/18/2023ABCBB
692/19/2023DEF
702/20/2023REEAA
712/21/2023ZNA
722/22/2023ABCYY
732/23/2023DEF
742/24/2023REECC
752/25/2023ZNA
762/26/2023ABC
772/27/2023DEF
782/28/2023REEFF
793/1/2023ZNA
803/2/2023ABC
813/3/2023DEF
823/4/2023REE
833/5/2023ZNAFF
843/6/2023ABC
853/7/2023DEF
863/8/2023REE
873/9/2023ZNAAA
883/10/2023ABC
893/11/2023DEF
903/12/2023REEBB
913/13/2023ZNA
923/14/2023ABC
933/15/2023DEFBB
943/16/2023REEEE
953/17/2023ZNAEE
963/18/2023ABCEE
973/19/2023DEFEE
983/20/2023REEEE
993/21/2023ZNAEE
1003/22/2023ABCEE
1013/23/2023DEFEE
1023/24/2023REEDD
1033/25/2023ZNAGG
1043/26/2023ABCRR
1053/27/2023DEFDD
1063/28/2023REECC
1073/29/2023ZNAYY
1083/30/2023ABCYY
1093/31/2023DEFBB
110
Sheet1
Cell Formulas
RangeFormula
B4:D4B4=DATE(2023,SEQUENCE(1,3,1,1),1)
B5:C14B5=SUMPRODUCT(--(Sheet1!$A$20:$A$109<=EOMONTH(B$4,0))* --(Sheet1!$A$20:$A$109>=B$4)* --($A$2 = Sheet1!$B$20:$B$109)*--($A5=Sheet1!$C$20:$C$109))
D5:D14D5=SUMPRODUCT( --(Sheet1!$A$20:$A$109>=D$4), --(Sheet1!$A$20:$A$109<=EOMONTH(D$4,0)), --($A$2 = Sheet1!$B$20:$B$109), --($A5=Sheet1!$C$20:$C$109))
Dynamic array formulas.
Cells with Data Validation
CellAllowCriteria
A2:A3List=$G$2:$G$5
I think you didn't get my point, what I need is to build a chart with dynamic ranges, where if I change the name of the leader, then the dynamic ranges of the chart will be changed according to the data and skip the blanks. I added data along with formulas to let you know what I need exactly:
Dynamic Ranges Chart.xlsx
A
2ZNA
Sheet1
Cells with Data Validation
CellAllowCriteria
A2ListABC, DEF, REE, ZNA
 
Upvote 0
I don't think you got what I wanted. What I want is to have dynamic ranges for the bar chart where if I change the leader name and populate the managers under each leader the ranges will be considering only the populated managers names along with their data. i.e. some leaders have 5 managers and other have 20+, this may cause blank ranges/cells. Here's the sample data:

Dynamic Ranges Chart.xlsx
ABCDEFGHIJKLMNOPQRST
1Dropdown list that has all Top Leader Names
2ZNAManager NameLeaderDateFormatted Date
3BBREE1/2/2023Jan-2023
4AAREE1/3/2023Jan-2023
5Manager NameJan-2023Feb-2023Mar-2023Apr-2023May-2023Jun-2023Jul-2023Aug-2023Sep-2023Oct-2023Nov-2023Dec-2023CCREE1/4/2023Jan-2023
64Q  3 1       DDREE1/5/2023Jan-2023
74R  3 1       EEREE1/6/2023Jan-2023
84S  4         FFREE1/7/2023Jan-2023
94T  4         GGREE1/8/2023Jan-2023
104V  4         HHREE1/9/2023Jan-2023
114Y  3   1     2GABC1/18/2023Jan-2023
124Z  4         2HABC1/19/2023Jan-2023
134X  6         2IABC1/20/2023Jan-2023
14            2JABC1/21/2023Jan-2023
15            2KABC1/22/2023Jan-2023
16            2LABC1/23/2023Jan-2023
17            2MABC1/24/2023Jan-2023
18            2NABC1/25/2023Jan-2023
19            2OABC1/26/2023Jan-2023
20            2PABC1/27/2023Jan-2023
21            3VDEF3/26/2023Mar-2023
22            3YDEF3/27/2023Mar-2023
23            3ZDEF3/28/2023Mar-2023
24            3XDEF3/29/2023Mar-2023
25            4QZNA3/30/2023Mar-2023
26            4RZNA3/31/2023Mar-2023
27            4SZNA3/3/2023Mar-2023
28            4TZNA3/4/2023Mar-2023
29            4VZNA3/5/2023Mar-2023
3000310201000004YZNA3/6/2023Mar-2023
314ZZNA3/7/2023Mar-2023
324XZNA3/8/2023Mar-2023
33BBREE1/2/2023Jan-2023
34AAREE1/3/2023Jan-2023
35CCREE1/4/2023Jan-2023
36DDREE1/5/2023Jan-2023
37EEREE1/6/2023Jan-2023
38FFREE1/7/2023Jan-2023
39GGREE1/8/2023Jan-2023
40HHREE1/9/2023Jan-2023
41RRREE1/10/2023Jan-2023
42YYREE1/11/2023Jan-2023
432AABC1/12/2023Jan-2023
442BABC1/13/2023Jan-2023
452CABC1/14/2023Jan-2023
462DABC1/15/2023Jan-2023
473ZDEF3/28/2023Mar-2023
483XDEF3/29/2023Mar-2023
494QZNA3/30/2023Mar-2023
504RZNA3/31/2023Mar-2023
514SZNA3/3/2023Mar-2023
524TZNA3/4/2023Mar-2023
534VZNA3/5/2023Mar-2023
544YZNA3/6/2023Mar-2023
554ZZNA3/7/2023Mar-2023
564XZNA3/8/2023Mar-2023
574XZNA3/8/2023Mar-2023
58BBREE1/2/2023Jan-2023
59AAREE1/3/2023Jan-2023
60CCREE1/4/2023Jan-2023
61DDREE1/5/2023Jan-2023
622KABC1/22/2023Jan-2023
632LABC1/23/2023Jan-2023
642MABC1/24/2023Jan-2023
652NABC1/25/2023Jan-2023
662OABC1/26/2023Jan-2023
672PABC1/27/2023Jan-2023
682QABC1/28/2023Jan-2023
692RABC1/29/2023Jan-2023
704QZNA5/30/2023May-2023
714RZNA5/31/2023May-2023
724SZNA3/3/2023Mar-2023
734TZNA3/4/2023Mar-2023
744VZNA3/5/2023Mar-2023
754YZNA7/6/2023Jul-2023
764ZZNA3/7/2023Mar-2023
774XZNA3/8/2023Mar-2023
784XZNA3/8/2023Mar-2023
79BBREE1/2/2023Jan-2023
80AAREE1/3/2023Jan-2023
81CCREE8/4/2023Aug-2023
82DDREE8/5/2023Aug-2023
832GABC1/18/2023Jan-2023
842HABC4/19/2023Apr-2023
852IABC4/19/2023Apr-2023
862JABC1/21/2023Jan-2023
872KABC1/22/2023Jan-2023
882LABC1/23/2023Jan-2023
892MABC1/24/2023Jan-2023
902NABC4/19/2023Apr-2023
912OABC1/26/2023Jan-2023
922PABC1/27/2023Jan-2023
932QABC4/19/2023Apr-2023
942RABC1/29/2023Jan-2023
952SABC1/30/2023Jan-2023
963SDEF3/24/2023Mar-2023
973TDEF3/25/2023Mar-2023
983VDEF3/26/2023Mar-2023
993YDEF3/27/2023Mar-2023
1003ZDEF3/28/2023Mar-2023
1013XDEF3/29/2023Mar-2023
1024QZNA3/30/2023Mar-2023
1034RZNA3/31/2023Mar-2023
1044SZNA3/3/2023Mar-2023
1054TZNA3/4/2023Mar-2023
1064VZNA3/5/2023Mar-2023
1074YZNA3/6/2023Mar-2023
1084ZZNA3/7/2023Mar-2023
1094XZNA3/8/2023Mar-2023
Sheet1
Cell Formulas
RangeFormula
A6:A13A6=UNIQUE(FILTER($Q$3:$Q$32,$R$3:$R$32=$A$2))
B6:M29B6=COUNTIFS($Q:$Q,$A6,$T:$T,B$5)
B30:M30B30=SUM(B6:B29)
T3:T109T3=TEXT(S3,"MMM-YYYY")
Dynamic array formulas.
Cells with Data Validation
CellAllowCriteria
A2ListABC, DEF, REE, ZNA
 
Upvote 0
I'm still confused.

How do you get a value of 3 for March for ZNA for manager Q3? You have a crosstab report chart, not data. Crosstab charts have source data. To attempt your request I had to make data to create that dynamic crosstab chart.

Cell A2 has a drop down so you can filter and make the crosstab dynamic. As far as blanks, I'm not sure what you mean - if you are asking for completely blank rows (no data during any time frame) for the MANAGERS that can be accomplished.

The Sample Data I gave you had multiple Managers with Same Leaders. If that never happens the report I did should still work, unless I am completely off of understanding what you want.
 
Upvote 0
I'm still confused.

How do you get a value of 3 for March for ZNA for manager Q3? You have a crosstab report chart, not data. Crosstab charts have source data. To attempt your request I had to make data to create that dynamic crosstab chart.

Cell A2 has a drop down so you can filter and make the crosstab dynamic. As far as blanks, I'm not sure what you mean - if you are asking for completely blank rows (no data during any time frame) for the MANAGERS that can be accomplished.

The Sample Data I gave you had multiple Managers with Same Leaders. If that never happens the report I did should still work, unless I am completely off of understanding what you want.
Sorry for the confusion. You're missing my point, my focus is to create dynamic ranges, I've seen somewhere where they used offset formula in Name Manager from Formulas Tab in excel and they replaced it the name they created in the chart ranges, this is what I need. my focus is not the data, it's dynamic ranges for chart. Does than make sense?
 
Upvote 0

Forum statistics

Threads
1,215,315
Messages
6,124,219
Members
449,148
Latest member
sweetkt327

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top