LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Macro to insert lines


I have a macro that will insert my selected lines underneath the las
entry. However, I can only get it to do this once, and in the sam
spot. How can I get it to keep adding lines after each entry if th
user needed to?

For example if I pressed the command button once, it would enter th
new set of lines and renumber it. If I wanted to enter more line
after this entry, I would press the button again and it would enter th
new blank lines and renumber in sequence. This is the macro
recorded.


Rows("10:12").Select
Selection.Copy
Range("A19").Select
ActiveSheet.Paste
Range("B16:B18").Select
Application.CutCopyMode = False
Selection.AutoFill Destination:=Range("B16:B21")
Type:=xlFillDefault
Range("B16:B21").Select

Can anyone help me out?

Thanks

--
tanyhar
-----------------------------------------------------------------------
tanyhart's Profile: http://www.excelforum.com/member.php...fo&userid=3514
View this thread: http://www.excelforum.com/showthread.php?threadid=54950

 
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
Macro to insert lines Linda Excel Worksheet Functions 2 April 10th 09 02:46 PM
macro to insert lines for 3 sections Don Excel Discussion (Misc queries) 0 June 12th 08 02:31 AM
macro to insert lines hiryuu Excel Programming 1 November 3rd 05 01:48 PM
Macro to insert blank lines Terry Pinnell Excel Discussion (Misc queries) 6 October 21st 05 11:21 PM
Macro insert lines Esrei Excel Discussion (Misc queries) 4 August 11th 05 11:51 AM


All times are GMT +1. The time now is 01:33 PM.

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"