T
Todd
Hello I would like to modify the 2nd macro that works and
hides rows by a cell in "column b" being empty to the 1st
macro which deletes rows based on cell in "column b" being
empty.
Please note I will have rows above and bleow the named
range of qty rows that need to stay. This is a parts list
sheet with profit calcs out the right hand side & I am
going to delete those parts that do not have a qty entered
in a particular column ( in this case "B")
If you do not like my barrowed macro then please suggest
something. I am also looking to delete same range same way
on another tab in the same work book but that is a nice to
have - the 1st part is the important issue).
This is first macro is the modified to delete macro:
Sub delete_zero_qty_items()
ActiveSheet.Unprotect
'qty_range is a named range in column b that goes from
B25 to B110
For Each c In Range("qty_range")
If IsEmpty(c.Value) Then
c.EntireRow.Delete
End If
Next c
Range("D8").Select
ActiveSheet.Unprotect
End Sub
This second macro is the original macro that I tried to
change.
Sub hide_zero_qty_rows_original_macro()
ActiveSheet.Unprotect
For Each c In Range("qty range")
If IsEmpty(c.Value) Then
c.EntireRow.Hidden = True
End If
Next c
Range("D8").Select
ActiveSheet.Unprotect
End Sub
Thank yo for your time
hides rows by a cell in "column b" being empty to the 1st
macro which deletes rows based on cell in "column b" being
empty.
Please note I will have rows above and bleow the named
range of qty rows that need to stay. This is a parts list
sheet with profit calcs out the right hand side & I am
going to delete those parts that do not have a qty entered
in a particular column ( in this case "B")
If you do not like my barrowed macro then please suggest
something. I am also looking to delete same range same way
on another tab in the same work book but that is a nice to
have - the 1st part is the important issue).
This is first macro is the modified to delete macro:
Sub delete_zero_qty_items()
ActiveSheet.Unprotect
'qty_range is a named range in column b that goes from
B25 to B110
For Each c In Range("qty_range")
If IsEmpty(c.Value) Then
c.EntireRow.Delete
End If
Next c
Range("D8").Select
ActiveSheet.Unprotect
End Sub
This second macro is the original macro that I tried to
change.
Sub hide_zero_qty_rows_original_macro()
ActiveSheet.Unprotect
For Each c In Range("qty range")
If IsEmpty(c.Value) Then
c.EntireRow.Hidden = True
End If
Next c
Range("D8").Select
ActiveSheet.Unprotect
End Sub
Thank yo for your time
