Filtering number of months through Input box

vinmam123VBA

New Member
Joined
Dec 18, 2020
Messages
21
Office Version
  1. 2019
Platform
  1. Windows
Hi All,

Can you please help me with below requirement:

I have column where I have months from Jan to Dec.

I would like to filter for the months. Some time only for 1 month and some time more than 1 month upto 6 months

Can you please help me with code where I should enter the number of months to be filtered and then I should be able to enter months name and filter the column accordingly

For example:

If I want to filter for Jan, Jun and Sep I should be able to enter Jan, Jun and Sep in input box to filter for these three months

If I want to filter for Two months(Jun and Oct) I should be able to enter in the input box and filter column for Jun and Oct.

Regards,
Vin
 

Excel Facts

Move date out one month or year
Use =EDATE(A2,1) for one month later. Use EDATE(A2,12) for one year later.

Dan5977

Board Regular
Joined
Aug 7, 2008
Messages
106
Office Version
  1. 2010
Would it not be easier to format as a table and you can then simply filter by unticking the months you don't want?
 

vinmam123VBA

New Member
Joined
Dec 18, 2020
Messages
21
Office Version
  1. 2019
Platform
  1. Windows
Would it not be easier to format as a table and you can then simply filter by unticking the months you don't want?
Thanks for the response. I am looking for code to include in one of my project. I believe Table will not help
 

Watch MrExcel Video

Forum statistics

Threads
1,129,658
Messages
5,637,618
Members
416,976
Latest member
LL1300

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
Top