Hide rows

ccoury09

Board Regular
Joined
Jun 5, 2008
Messages
58
I have a spreadsheet of tasks that I have for myself. When I have completed the task, I mark in column D "Done". I want to make it so that everytime I mark a task as "done" the row gets hidden. This way all that will ever appear are the open items I still have. (But I will have the ability to see those rows hidden if I need to look at old tasks)

Thanks! :)
 

Excel Facts

Last used cell?
Press Ctrl+End to move to what Excel thinks is the last used cell.
Try this. Right click the sheet tab and select View Code, then paste in

Code:
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Column <> 4 Then Exit Sub
Application.EnableEvents = False
If UCase(Target.Value) = "DONE" Then Target.Rows.EntireRow.Hidden = True
Application.EnableEvents = False
End Sub


Close the code window using the X.
 
Upvote 0
Thank you. It seems to have worked for the first row I designated as "Done", but all the others don't hide... any additional suggestions?
 
Upvote 0
Try

Code:
Sub Rplc()
Dim c As Range
For Each c In Selection
    If UCase(Ac.Value) = "DONE" Then Target.Rows.EntireRow.Hidden = True
Next c
End Sub


in a regular module.
 
Upvote 0
Try

Code:
Sub Rplc()
Dim c As Range
For Each c In Selection
    If UCase(Ac.Value) = "DONE" Then Target.Rows.EntireRow.Hidden = True
Next c
End Sub


in a regular module.


It errors out on the "If UCase(Ac.Value) = "DONE" Then " piece.


Every time I go into it fresh, I can get it to let one of the Done rows hide... Does that help any?

Thanks again for your patience with me. I am VERY new to all this. :)
 
Upvote 0
Sorry, typo (fat fingers):

Code:
If UCase(c.Value) = "DONE" Then Target.Rows.EntireRow.Hidden = True
 
Upvote 0

Forum statistics

Threads
1,213,510
Messages
6,114,044
Members
448,543
Latest member
MartinLarkin

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top