Results 1 to 11 of 11

Thread: Delete all rows under a group

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #2
    VBAX Tutor
    Joined
    Jun 2012
    Posts
    269
    Location
    This might work for you...

    Sub deleteAll()
        Dim rng As Range
        Dim rngDelete As Range
        Set rng = Sheet1.Range("B:B")
        Set rngDelete = rng.Find(What:="Closed Accounts")
        Sheet1.Range("B" & rngDelete.Row & ":B" & Sheet1.Range("B65536").End(xlUp).Row).EntireRow.delete
    End Sub
    Last edited by Aussiebear; 02-24-2025 at 03:39 AM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •