![]() |
|
#1
|
|||
|
|||
|
Hi How to insert an empty row every 100 rows? The file contains 24000 rows in two columns. thanks. Yacov |
|
#2
|
|||
|
|||
|
This code uses Col A as a means to track where to insert a blank row.
Code:
Option Explicit
Sub InsertBlankRows()
Dim lr As Long, r As Long
On Error Resume Next
Application.ScreenUpdating = False
For r = Cells(Rows.Count, "A").End(xlUp).Row To 2 Step -100
If Range("A" & r) <> "" And Range("A" & r - 100) <> "" Then Rows(r).Insert (1)
Next r
Application.ScreenUpdating = True
End Sub
|
|
#3
|
|||
|
|||
|
thanks. works great
|
|
#4
|
|||
|
|||
|
You are welcome.
|
|
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| If a2 is not empty, color empty cells in b2:af2 | turkanet | Excel | 2 | 08-20-2017 11:00 PM |
Picture content control -> insert picture -> empty?
|
Jaymond Flurrie | Word | 3 | 07-13-2016 07:00 AM |
How do I insert pictures directly into picture boxes by clicking the box instead of using INSERT>PIC
|
Bree | Word | 1 | 06-24-2016 10:32 PM |
automatic insert hypens until the end of the row and in empty rows between paragraphs
|
Ivica | Word | 3 | 12-28-2015 01:31 PM |
| Apparently empty (blank) cells aren't empty | daymaker | Excel | 3 | 03-08-2012 03:41 PM |