ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Deleting a row if closing date elapsed (https://www.excelbanter.com/excel-worksheet-functions/140567-deleting-row-if-closing-date-elapsed.html)

bollard

Deleting a row if closing date elapsed
 
Hello

I want to delete a row if the closing date shown in one column of that row
is equal to, or before today's date.

Can anyone offer the correct conditional format, or is it a job for a Macro?

Not very well up on Macros, so please treat me as a numbskull!!!

Max

Deleting a row if closing date elapsed
 
One way is to use autofilter ..

Try this on a spare copy:
Autofilter on the dates col, choose "Custom"
In the dialog, select: less than or equal to,
then type in today's date into the box, eg: 4/27/2007 (key in the full date)
Click OK. This should filter out all rows to be deleted. Simply select all
the filtered row headers, right-click Delete Row.
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---


"bollard" wrote:

Hello

I want to delete a row if the closing date shown in one column of that row
is equal to, or before today's date.

Can anyone offer the correct conditional format, or is it a job for a Macro?

Not very well up on Macros, so please treat me as a numbskull!!!


bollard

Deleting a row if closing date elapsed
 
Hi Max

I really want the row to delete automatically once we reach the closing
date. Can you help with that, please?

"Max" wrote:

One way is to use autofilter ..

Try this on a spare copy:
Autofilter on the dates col, choose "Custom"
In the dialog, select: less than or equal to,
then type in today's date into the box, eg: 4/27/2007 (key in the full date)
Click OK. This should filter out all rows to be deleted. Simply select all
the filtered row headers, right-click Delete Row.
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---


"bollard" wrote:

Hello

I want to delete a row if the closing date shown in one column of that row
is equal to, or before today's date.

Can anyone offer the correct conditional format, or is it a job for a Macro?

Not very well up on Macros, so please treat me as a numbskull!!!


Max

Deleting a row if closing date elapsed
 
Welcome back <g ..

One way to achieve it, which extracts only the current cases in a new sheet
....

Source data is assumed input continuously in a sheet: X,
within cols A to D, data from row2 down,
where the key col = col A (real dates)

In a new sheet: Current Cases,
Copy n paste the same col labels in X into B1:E1

Put in A2:
=IF(X!A2="","",IF(X!A2<=TODAY(),"",ROW()))
Leave A1 blank

Put in B2:
=IF(ROW(A1)COUNT($A:$A),"",INDEX(X!A:A,SMALL($A:$ A,ROW(A1))))

Copy B2 across to E2. Select A2:E2, fill down to cover the max expected
extent of source data in X, eg down to E200. Format col B as date. The above
will auto-return the required results, ie only the source lines from X with
dates today (ie the current/unexpired cases), with all lines neatly bunched
at the top.
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"bollard" wrote:
Hi Max

I really want the row to delete automatically once we reach the closing
date. Can you help with that, please?



Max

Deleting a row if closing date elapsed
 
A sample construct for the earlier suggestion is available at:
http://www.savefile.com/files/762606
Copy current unexpired rows to new sheet.xls
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---


All times are GMT +1. The time now is 03:08 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com