Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
insert 3 rows before any text in column A
Help!
thank you in advance for any help to this situation. i need a application level macro (if possible, meaning to be able t run on anyworkbook) to insert 3 rows above and text that is found i column "A". so if "what" is in column A i need 3 rows above it or i the text is "Juan Baldez" then 3 rows and so on. once again thanks fo the fix in advance. Kimme -- Message posted from http://www.ExcelForum.com |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
insert 3 rows before any text in column A
Hi Kimmer,
The following will insert rows as required on the activesheet, Column A. The rows will be inserted from row 4 down to the last item found Actually, it does it the other way around! Sub Test() Dim CurRow, C CurRow = Cells(Rows.Count, "A").End(xlUp).Row Do If Cells(CurRow, 1) "" Then For C = 1 To 3 Rows(CurRow).Insert Next End If CurRow = CurRow - 1 Loop Until CurRow = 4 End Sub regards, Don "onesaint " wrote in message ... Help! thank you in advance for any help to this situation. i need a application level macro (if possible, meaning to be able to run on anyworkbook) to insert 3 rows above and text that is found in column "A". so if "what" is in column A i need 3 rows above it or if the text is "Juan Baldez" then 3 rows and so on. once again thanks for the fix in advance. Kimmer --- Message posted from http://www.ExcelForum.com/ |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
insert 3 rows before any text in column A
QUite Nice Don! it works like a charm. thanks again for the help.
Kimme -- Message posted from http://www.ExcelForum.com |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Insert cell text every 5 rows in a column | Excel Discussion (Misc queries) | |||
Insert Column after specific text title the new column and add for | Excel Discussion (Misc queries) | |||
Text to Rows and then Insert Blank Rows | Excel Discussion (Misc queries) | |||
how insert same text in empty cells in column (10000 rows) | Excel Worksheet Functions | |||
Insert Rows after text appears in column | Excel Programming |