Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
This is the first part:
Sub Macro1() Dim i As Integer For i = 200 To 1 Step -1 If IsEmpty(Cells(i, 4)) Then Rows(i).EntireRow.Delete End If Next End Sub This will scan up column D from row 200 to 1 deleting all rows with empties -- Gary''s Student "Chris_t_2k5" wrote: Here is my problem. I have data for example C1:D200. All of C1:C200 have values in but only certain cells in D1:D200 have values in them. Is it possible to create a macro that will delete the rows for a certain selection where D have no values in? Also - after this has been done and there are say 20 values in each column of C1:D20 is it possible to insert say 200 blank rows after each value. (eg C1 has value, D1 has value, C201 has value, D201 has value etc...) Thanks |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Delete blank rows | Excel Discussion (Misc queries) | |||
Delete blank rows in selection | Excel Programming | |||
Delete Multiple Rows based on Selection | Excel Programming | |||
Need to delete rows relative to selection | Excel Programming | |||
Delete blank row only if 2 consecutive blank rows | Excel Programming |