Return array of data by date range

K

Ken King

I am trying to determine if VLOOKUP can search an array by any day within a
calendar month (look_up_value) and return a list of names in the adjacent
column (table_array).
Ken
 
G

GSnyder

I believe you're saying you'd like to have a list of dates in one column (A)
and a corresponding list of month names in another (B). You could set up a
table of data off to the side or on another sheet which contains the list of
month numbers and month names like this:

Month_Num Month_Name
1 January
2 February
3 March
etc etc

To get the name of the month into column B, you would just VLOOKUP the month
in the table like this:

=VLOOKUP(MONTH(A2),$Y$1:$Z$15,2,0)

This assumes the list of month names is in Y1:Z15.

A better solution to this problem might be to have column B just = column A.
Then format column B as the month name only by going into Format Cells ->
Custom and typing MMMM in the custom format box. Then, column B will
ACTUALLY be the dates, but will LOOK like the month names.

Does that work?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top