J
Joanne
Hello all
I'm certainly no expert, and I'm trying to botch my way through this
project. Surprise, surprise I got stuck again
I found a macro on the web:
http://excel.tips.net/Pages/T001940_Hiding_Rows_Based_on_a_Cell_Value.html
I adjusted it a bit, but it's still not working, can anyone help? I'm
looking for a macro that will hide/unhide rows depending on whether the value
in the N column is "Yes", or "-". If "Yes" then show, if "-" then hide. The
value could change so the macro needs to be able to handle that as well.
Thanks in advance
Sub HideRows()
BeginRow = 51
EndRow = 1354
ChkCol = 14
For RowCnt = BeginRow To EndRow
If Cells(RowCnt, ChkCol).Value = "-" Then
Cells(RowCnt, ChkCol).EntireRow.Hidden = True
Else
Cells(RowCnt, ChkCol).EntireRow.Hidden = False
End If
Next RowCnt
End Sub
I'm certainly no expert, and I'm trying to botch my way through this
project. Surprise, surprise I got stuck again
I found a macro on the web:
http://excel.tips.net/Pages/T001940_Hiding_Rows_Based_on_a_Cell_Value.html
I adjusted it a bit, but it's still not working, can anyone help? I'm
looking for a macro that will hide/unhide rows depending on whether the value
in the N column is "Yes", or "-". If "Yes" then show, if "-" then hide. The
value could change so the macro needs to be able to handle that as well.
Thanks in advance
Sub HideRows()
BeginRow = 51
EndRow = 1354
ChkCol = 14
For RowCnt = BeginRow To EndRow
If Cells(RowCnt, ChkCol).Value = "-" Then
Cells(RowCnt, ChkCol).EntireRow.Hidden = True
Else
Cells(RowCnt, ChkCol).EntireRow.Hidden = False
End If
Next RowCnt
End Sub