View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Radhakant Panigrahi Radhakant Panigrahi is offline
external usenet poster
 
Posts: 45
Default Comment in every 10 the row

Hi Can anybody help in making a VBA

I have column A and B and I need a comment "AUDIT"in column C at every
11 row of column C.

I have tried the below but does not work

Sub MyMacro()
Dim lngRow As Long
For lngRow = 11 To Cells(Rows.Count, "D").End(xlUp).Row Step 11
If Range("D" & lngRow).Comment Is Nothing Then
Range("D" & lngRow).AddComment "Audit"
End If
Next
End Sub