Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1
Default Find the row number with a date in it

I am trying to find the row number, to use in a formula, of a row with
a date 365 days or 1 year ago.

I need this to perform some cacluations on the last 12 months worth of
data. Is there a simple excel function to do this or will I need a
makro?

Thanks

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,726
Default Find the row number with a date in it

=match(today()-365,rng,0)

--
---
HTH

Bob

(change the xxxx to gmail if mailing direct)


wrote in message
oups.com...
I am trying to find the row number, to use in a formula, of a row with
a date 365 days or 1 year ago.

I need this to perform some cacluations on the last 12 months worth of
data. Is there a simple excel function to do this or will I need a
makro?

Thanks



  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,345
Default Find the row number with a date in it

In case there is not an exact matching date try:

=MIN(IF(F1:F31=DATE(YEAR(TODAY())-1,MONTH(TODAY()),DAY(TODAY())),F1:F31))

Array entered with Control + Shift + Enter instead of just Enter otherwise
you will get a date of January 1 1900

--
HTH

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


with @tiscali.co.uk


wrote in message
oups.com...
I am trying to find the row number, to use in a formula, of a row with
a date 365 days or 1 year ago.

I need this to perform some cacluations on the last 12 months worth of
data. Is there a simple excel function to do this or will I need a
makro?

Thanks



  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,345
Default Find the row number with a date in it

Of course, unlike Bob, I did not read your question properly. To get the
Row number try:

=MATCH(MIN(IF(F6:F36=DATE(YEAR(TODAY())-1,MONTH(TODAY()),DAY(TODAY())),F6:F36)),F6:F36,0)

Still Array entered. If your data does not start in Row 1 then add
+(whatever the Row number before the start of your data is) at the end of
the formula.

--
HTH

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


with @tiscali.co.uk


"Sandy Mann" wrote in message
...
In case there is not an exact matching date try:

=MIN(IF(F1:F31=DATE(YEAR(TODAY())-1,MONTH(TODAY()),DAY(TODAY())),F1:F31))

Array entered with Control + Shift + Enter instead of just Enter otherwise
you will get a date of January 1 1900

--
HTH

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


with @tiscali.co.uk


wrote in message
oups.com...
I am trying to find the row number, to use in a formula, of a row with
a date 365 days or 1 year ago.

I need this to perform some cacluations on the last 12 months worth of
data. Is there a simple excel function to do this or will I need a
makro?

Thanks





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
Date formulas DRondeau Excel Discussion (Misc queries) 7 September 6th 06 09:53 PM
Mileage Claim Formula johndavies New Users to Excel 4 August 14th 06 09:24 AM
Need help to find a date (latest date) from a column Max Excel Worksheet Functions 0 March 20th 06 02:49 PM
Excel: I enter date and format for date, but shows as number spohar Excel Discussion (Misc queries) 2 March 10th 06 08:40 PM
NETWORKDAYS - Multiple Date Selection Annabelle Excel Discussion (Misc queries) 3 October 4th 05 07:04 PM


All times are GMT +1. The time now is 11:41 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"