Thread: Latest date
View Single Post
  #9   Report Post  
Posted to microsoft.public.excel.programming
ChristinaC ChristinaC is offline
external usenet poster
 
Posts: 8
Default Latest date

It would help if I read your instructions properly. It works and works well.
Many thanks for your assistance.

"ChristinaC" wrote:

Thanks, I will try this only I am not sure how this works when you have two
different po's with the same date.

"Tom Ogilvy" wrote:

So sort it by Po No and date (ascending) so the last record for each Po No
will be the latest date

then in the next available column put in a formula like (assume D2 for your
example)

=if(A2<A3,"Last","")

then drag fill down the column.

Now select A1 and do Data=filter=Autofilter
select the dropdown in D and select Last from the dropdown choices.

This should give you the list you need

You can select your data and copy it to a new worksheet. (Only the visible
cells will be copied).

To turn off the filter, repeat Data=Filter=Autofilter

This approach could be implemented in code as well.

--
Regards,
Tom Ogilvy

"ChristinaC" wrote in message
...
The data can be sorted like this but the object of the exercise is to get

a
list of unique purchase orders of one line with the latest date. If there

is
a po with only one line then that would be unique. Hope this makes sense.

"Tom Ogilvy" wrote:

Can the data be sorted on Po No and Date. Can a formula be put in the

next
adjacent column. Where do you want the output? I assume this is a list

of
unique Po No with corresponding latest dates?

--
Regards,
Tom Ogilvy

"ChristinaC" wrote in message
...
Can someone help me with this one. I have a spreadsheet with a list

of
Purchase orders that have more than one line. Eg

Po No Line Date
no
po12345 1 18/02/2004
po12345 2 05/04/2005
po12345 3 16/02/2003
po12345 4 06/02/2004
po12346 1 09/02/2005 etc.....

Can someone show me what code I need to use to find the latest date in

the
third column against each po number. Hope this makes sense.