Public Schedule Face-to-Face & Online Instructor-Led Training - View dates & book

how delete cells occur

Forum home » Delegate support and help forum » Microsoft Excel Training and help » How to delete cells that occur every 3rd cell

How to delete cells that occur every 3rd cell

ResolvedVersion 2003

Suyeon has attended:
Excel Advanced course
Excel VBA Intro Intermediate course
Access Advanced course

How to delete cells that occur every 3rd cell

how do I programme vba so that I can delete every 3rd cell ( populated) going down?

Many thanks

RE: how to delete cells that occur every 3rd cell

Hi again Suyeon

This time place the cursor in the top cell first.
Then using a Do loop every third cell down is deleted until a black cell is reached.

Sub DeleteEveryThird()
'Place cursor in top cell first

Do Until ActiveCell.Value = ""
ActiveCell.Offset(2, 0).Select
ActiveCell.Delete Shift:=xlUp
Loop

End Sub

Regards
Doug
Best STL

Wed 25 Jul 2012: Automatically marked as resolved.

Excel tip:

Highlighting a data range

Attempting to use a mouse to highlight a large range of cells with data in Excel can make the mouse to have a life of it's own!

Use keyboard strokes instead.

Step 1. Place the cusor in the cell where the highlighting should begin.

Step 2. Select keystroke, CTRL+SHIFT+END

This will take the cursor to the furthermost bottom corner of the data range found in that worksheet. And highlight that range of cells at the same time




View all Excel hints and tips

Connect with us:

0207 987 3777

Call for assistance

Request Callback

We will call you back

Server loaded in 0.09 secs.