PC Review


Reply
Thread Tools Rate Thread

Determine which column to use by date

 
 
Mike Griffin
Guest
Posts: n/a
 
      28th Feb 2006
I have a range of 14 rows by 12 columns. Each column represents a
different month. How can I determine which column to use, if I only
want to use the column for the current month?

 
Reply With Quote
 
 
 
 
=?Utf-8?B?R2FyeScncyBTdHVkZW50?=
Guest
Posts: n/a
 
      1st Mar 2006
lets say cols A-L are Jan thru Dec

=MONTH(TODAY()) formatted as an integer will tell you which column to use
for the current date.
--
Gary's Student


"Mike Griffin" wrote:

> I have a range of 14 rows by 12 columns. Each column represents a
> different month. How can I determine which column to use, if I only
> want to use the column for the current month?
>
>

 
Reply With Quote
 
Pete_UK
Guest
Posts: n/a
 
      1st Mar 2006
The function TODAY() will give today's date. With the MONTH( ) function
wrapped around this, you will get the month (eg 3 for March), so you
will need to add something to this to suit your range. Say for example
your range starts in column F for January (i.e. the 6th column), then
this formula:

=MONTH(TODAY())+5

would give the column number. If you want this as a letter, then this
amendment:

=CHAR(64+MONTH(TODAY())+5)

would suffice.

Hope this helps.

Pete

 
Reply With Quote
 
Mike Griffin
Guest
Posts: n/a
 
      1st Mar 2006
Yes, that gets me the column!

Now, my question is how to use that column letter or number in another
formula concatenated with the row number.

eg. =IF($(CHAR(64+MONTH(TODAY())+5)$3='NO', blah, blah))

I hope that makes sense

 
Reply With Quote
 
Mike Griffin
Guest
Posts: n/a
 
      1st Mar 2006
I actually figured it out.

=ADDRESS(3, MONTH(TODAY())+8, 3)

Thanks

 
Reply With Quote
 
Pete_UK
Guest
Posts: n/a
 
      2nd Mar 2006
Glad you got it working, Mike. Thanks for feeding back.

Pete

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Determine a result of one column based on conditions in two column tel703 Microsoft Excel Misc 1 25th Mar 2010 05:01 PM
Determine Max and Min date in Column QB Microsoft Excel Programming 3 2nd May 2009 04:52 AM
formual to determine if date falls on weekend, adjust date to Mond Bradley Microsoft Excel Misc 4 21st Nov 2008 06:19 PM
Determine Column Width and Bound Column =?Utf-8?B?Q3luZHlH?= Microsoft Access Forms 1 27th Apr 2005 04:48 AM
Determine start column/ end column of Merged Cell jC! Microsoft Excel Programming 3 8th Jul 2004 12:05 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 03:48 AM.