View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Danny
 
Posts: n/a
Default Macro - Delete Comments - What if there's none?

Hi,

I inserted the Macro below into a series of macros. If there is(are) NO
comment(s) in the worksheet, my macros will not run properly. Please edit my
macro so if there is(are) NO comment(s), the rest of the macros will still
run.

Sub DeleteComments()
Application.Goto Reference:="My_Range"
Selection.SpecialCells(xlCellTypeComments).Select
Selection.EntireRow.Delete
End Sub

Thank You.