VBA - Search worksheets and find current month

Simbo2015

New Member
Joined
May 5, 2015
Messages
24
Hi, I'm hoping someone may be able to help.

Is there a way in VBA to search the worksheets (which are labelled jan, feb, mar.....etc) and open/select the one which matches the current month?

Would I need a verification cell which has the current month in or can it all be done in VBA?

Thanks in advance.
 

Excel Facts

How to find 2nd largest value in a column?
MAX finds the largest value. =LARGE(A:A,2) will find the second largest. =SMALL(A:A,3) will find the third smallest
Try something like this...

Sheets(Format(Date, "mmm")).Select

If run today, it should select a sheet with a tab name Jun.
 
Upvote 0

Forum statistics

Threads
1,196,053
Messages
6,013,118
Members
441,749
Latest member
batel19

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