#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 385
Default Newest month formula

I have a sheet with all 12 months and then I have a column next to the total
column that displays the data from the newest month.

Ex.

May Jun | | Total
1 1 1 2
1 2 2 3

The column that displays June's data again basically makes it easier for me
to look at and manipulate later.

Is there a way to automatically have that column update if I add data in a
July column?
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,345
Default Newest month formula

Assuming that the months are in Columns B:M try:

=IF(COUNT(B2:M2)=0,"",LOOKUP(10^10,B2:M2))

to return the latest month's figure and copy down as required

--
HTH

Sandy
In Perth, the ancient capital of Scotland
and the crowning place of kings


Replace @mailinator.com with @tiscali.co.uk


"Jennifer" wrote in message
...
I have a sheet with all 12 months and then I have a column next to the
total
column that displays the data from the newest month.

Ex.

May Jun | | Total
1 1 1 2
1 2 2 3

The column that displays June's data again basically makes it easier for
me
to look at and manipulate later.

Is there a way to automatically have that column update if I add data in a
July column?



  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 74
Default Newest month formula

Jennifer,

In your 'latest' column, you can use and HLOOKUP formula to return the
latest month.

A B C D
Jan-08 Feb-08 Mar-08 Apr-08
1 2 2 4
2 2 2 1
3 5 3 5
etc

(The Jan-08 must be formatted as a date.)

Use this formula:
=HLOOKUP(MAX(A1:L1),A2:L20,1)

The first part of the formula MAX(A1:L1) will return the largest month
(since there are twelve months, A-L are the columns)

The second part is all of the data. So, if you have 20 rows of data, you
should type in A2:L20

The third part of the formula is how many cells down from the referenced
cell it looks. So, if it finds that Jun-08 is the largest date entered, it
will then look down one to return the first number. The second cell in your
'latest' column should look like this:
=HLOOKUP(MAX(A1:L1),A2:L20,2)

Make sense?

"Jennifer" wrote:

I have a sheet with all 12 months and then I have a column next to the total
column that displays the data from the newest month.

Ex.

May Jun | | Total
1 1 1 2
1 2 2 3

The column that displays June's data again basically makes it easier for me
to look at and manipulate later.

Is there a way to automatically have that column update if I add data in a
July column?

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 20
Default Newest month formula

if the most recent month column (C) will always be next to the most
recent month (column B), could just use =OFFSET(C2,0,-1), then when
you insert a new month in between june and the most recent it will
adjust to the new one

On Jul 1, 12:05*pm, Jennifer
wrote:
I have a sheet with all 12 months and then I have a column next to the total
column that displays the data from the newest month.

Ex.

May * * Jun * * | * | * * Total
1 * * * * *1 * * * * 1 * * * * *2
1 * * * * *2 * * * * 2 * * * * *3

The column that displays June's data again basically makes it easier for me
to look at and manipulate later.

Is there a way to automatically have that column update if I add data in a
July column?


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Automatically use the newest number input in the formulas JessieB Excel Discussion (Misc queries) 1 January 11th 08 07:38 PM
Trying to get a Boolean formula to work month-to-month mstieler Excel Discussion (Misc queries) 4 July 18th 07 10:12 PM
Finding the oldest & newest dates Bob Smith Excel Worksheet Functions 3 April 13th 07 02:27 PM
Special sort for oldest and newest date DTTODGG Excel Discussion (Misc queries) 1 October 11th 06 05:17 PM
Function or formula to convert "text" month to number of month Steve Vincent Excel Discussion (Misc queries) 1 February 4th 06 04:19 PM


All times are GMT +1. The time now is 07:33 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"