Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 989
Default Max date in auto-filtered range

Hi.

I have a column of roughly 20,000 dates.

There are other fields, upon which some autofilters are applied.

When those filtering criteria are applied, I need to obtain the maximum date
of the visible dates that are left...

I put in a formula =if(subtotal(3,rgDateRange),<dateAddress,0) formula to
identify the values of the dates that are visible, but I'm not sure that's
needed.

I also think an array formula could do it, but I could use some more
experience with that.

Optimally, I only need to know one value from the visible range... the
maximum one.

Suggestions? Thanks.
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,494
Default Max date in auto-filtered range

wouldn't the subtotal function work?

=SUBTOTAL(104,Your date range)

--


Gary


"mark" wrote in message
...
Hi.

I have a column of roughly 20,000 dates.

There are other fields, upon which some autofilters are applied.

When those filtering criteria are applied, I need to obtain the maximum
date
of the visible dates that are left...

I put in a formula =if(subtotal(3,rgDateRange),<dateAddress,0) formula
to
identify the values of the dates that are visible, but I'm not sure that's
needed.

I also think an array formula could do it, but I could use some more
experience with that.

Optimally, I only need to know one value from the visible range... the
maximum one.

Suggestions? Thanks.



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 989
Default Max date in auto-filtered range

Got it, I think.

This seems to do what I want:

Application.WorksheetFunction.Max(Range("rgDates") .SpecialCells(xlCellTypeVisible))


  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 989
Default Max date in auto-filtered range

wouldn't the subtotal function work?
=SUBTOTAL(104,Your date range)



Thanks, Gary. You're right, it does.

I tended only to use =subtotal(3,range) and =subtotal(9,range)

Thanks for directing me to this one.

Mark
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
Auto Sum a Range of Cells based on the date jcpotwor Excel Discussion (Misc queries) 3 January 17th 07 07:20 PM
Auto Date range and printing. Houm Excel Programming 0 March 31st 05 05:38 PM
Calculating a auto filtered range Tom Ogilvy Excel Programming 1 September 2nd 04 10:11 AM
traversing through a filtered range based on another filtered range zestpt[_4_] Excel Programming 4 July 12th 04 06:37 PM
Cells.Find in Auto-Filtered range mark Excel Programming 2 September 16th 03 11:55 PM


All times are GMT +1. The time now is 12:47 AM.

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

About Us

"It's about Microsoft Excel"