Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Insert rows on multiple sheets

Sub Tester4()
Worksheets.Select
ActiveCell.Offset(1, 0).EntireRow.Select
Selection.Insert
Selection.Offset(-1, 0).EntireRow.Select
Selection.EntireRow.Borders(xlEdgeTop).LineStyle = xlNone
Worksheets("Sheet1").Select

End Sub


"Steve" wrote in message
news:3fabaab3$2$18253$afc38c87@...
Hi everyone. I have a workbook with 4 sheets in it. Sheet 1....Sheet 4.

The user will always be on Sheet1. I wrote simple macro that inserts a

row
under the active cell when the user hits Ctl I:

ActiveCell.Offset(1, 0).EntireRow.Insert
ActiveCell.Offset(1, 0).Activate
ActiveCell.EntireRow.Borders(xlEdgeTop).LineStyle = xlNone

So for instance, if the active cell is on row 25, a row is inserted

beneath.
My question: how do I get the macro to also insert a row under row 25 on
the 3 other sheets?

Thanks!!




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Insert row on multiple sheets aussiegirlone Excel Discussion (Misc queries) 6 July 17th 09 12:54 PM
Insert row on multiple sheets aussiegirlone Excel Discussion (Misc queries) 0 July 16th 09 04:01 AM
How do you insert rows into multiple sheets in a workbook? Marketing Queen Excel Discussion (Misc queries) 2 May 30th 06 05:33 PM
insert Rows with Formulas in Place on Multiple Sheets? Michael Link Excel Discussion (Misc queries) 5 March 9th 06 01:54 PM
Links between sheets in error due to insert rows Sarah Excel Discussion (Misc queries) 5 March 3rd 06 06:31 PM


All times are GMT +1. The time now is 10:03 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"