Help with VBA Index Match.

LordH

New Member
Joined
Oct 14, 2014
Messages
2
Hi Everyone,

I've encountered a bit of a problem and would love some help with some coding & VBA .

I have a personal finance budget and I usually go through different months (cell F2 in overview sheet which I have since defined & named as "Period" ) to check things. This is a drop-down list. But I could be in Dec of last year and would like to easily go to the current month.

I need a VBA code that allows me to search through the pay periods (in relation to today's date) in first picture and insert that into the bit in blue (cell F2 or period in overview) .

I would normally use an excel function as per below but would rather have a macro that can input the relevant pay date into the cell E2 in Sheet "Overview".

I would normally use something like this in excel but not sure when it comes to vba.

" =INDEX(Table10[Period Date],MATCH(TODAY(),Table10[After Date],1)) "

any help would be greatly appreciated,



m2kkJ6

Capture.png



Capture2.png
 

Excel Facts

What is =ROMAN(40) in Excel?
The Roman numeral for 40 is XL. Bill "MrExcel" Jelen's 40th book was called MrExcel XL.

Forum statistics

Threads
1,215,767
Messages
6,126,774
Members
449,336
Latest member
p17tootie

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