Dynamic chart based on month

Plexzuz

New Member
Joined
Jan 14, 2024
Messages
3
Office Version
  1. 365
Platform
  1. Windows
Hello! My firts post here! My English isnt great, but i will try anyway!

What i need is a dynamic chart that change the value on the chart based on a drop down list.
All the data i have is in sheet 1 named "2023". the other other sheet where i have all the charts is in sheet 2 "Graf".
In sheet 1(2023) the date is sorted from A2->A366 In the format 01.01.2023->31.12.2023.
the data is also in sheet 1 D2->D366.

I want a drop down list in sheet 2(graf) at Z2 to choose from January->Desember (I got it in norwegian btw. Dont know if that has anything to say) and pick up the date and data from sheet 1 for the month January->Desember. so when i choose January it will change the chart on sheet 2 and update the data there based on the month in the dropdown list.

How can i do this?
 

Attachments

  • Sheet 1.PNG
    Sheet 1.PNG
    114.8 KB · Views: 9
  • Sheet 2.PNG
    Sheet 2.PNG
    70.4 KB · Views: 9

Excel Facts

Is there a shortcut key for strikethrough?
Ctrl+S is used for Save. Ctrl+5 is used for Strikethrough. Why Ctrl+5? When you use hashmarks to count |||| is 4, strike through to mean 5.
Filter is a newer dynamic function. This is probably a good place to start.

Here is a good overview:

 
Upvote 1
Here is a sample data table. Its name is tblData
DateData
1/1/202310
1/2/202315
1/3/202320
1/4/202325
1/5/202330
1/6/202335
1/7/202340
1/8/202345
1/9/202350
1/10/202355
1/11/202360
1/12/202365
1/13/202370
1/14/202375
1/15/202380
1/16/202385
1/17/202390
1/18/202395
1/19/2023100
1/20/2023105
1/21/2023110
1/22/2023115
1/23/2023120
1/24/2023125
1/25/2023130
1/26/2023135
1/27/2023140
1/28/2023145
1/29/2023150
1/30/2023155
1/31/2023160
2/1/2023165
2/2/2023170
2/3/2023175
2/4/2023180
2/5/2023185
2/6/2023190
2/7/2023195
2/8/2023200
2/9/2023205
2/10/2023210
2/11/2023215
2/12/2023220
2/13/2023225
2/14/2023230
2/15/2023235
2/16/2023240
2/17/2023245
2/18/2023250
 
Upvote 0
Now on your graf page.

1. Put a drop down list with your dates. Mine are 1/1/2023, 2/1/2023
the cell is in C2

2. Put this formula where you want the chart data
=FILTER(tblData, MONTH(tblData[Date]) = MONTH(C2), "")

3. Now highlight the data and add your chart.

I'll post a sample in second
 
Upvote 0
Book1
BCDEFGHIJKLMNOPR
1Chart Data
2Filter1/1/20231/1/202310
31/2/202315
41/3/202320
51/4/202325
61/5/202330
71/6/202335
81/7/202340
91/8/202345
101/9/202350
111/10/202355
121/11/202360
131/12/202365
141/13/202370
151/14/202375
161/15/202380
171/16/202385
181/17/202390
191/18/202395
201/19/2023100
211/20/2023105
221/21/2023110
231/22/2023115
241/23/2023120
251/24/2023125
261/25/2023130
271/26/2023135
281/27/2023140
291/28/2023145
301/29/2023150
311/30/2023155
321/31/2023160
Graf
Cell Formulas
RangeFormula
F2:G32F2=FILTER(tblData, MONTH(tblData[Date]) = MONTH(C2), "")
Dynamic array formulas.
Cells with Data Validation
CellAllowCriteria
C2List=$Q$2:$Q$3
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,181
Members
453,022
Latest member
Mohamed Magdi Tawfiq Emam

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