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: 55
Default Run-time error when copying entire row!

Hi
I have the following code:
ActiveSheet.Range("LastLine").Select 'range name
ActiveCell.Offset(-1, 0).EntireRow.Copy
Selection.EntireRow.Insert
Application.CutCopyMode = False
Range("Lastline").Offset(-1, 0).Select

On my lastline i have totals for various columns. So i copy the entire row of the previous row and insert it after the copied row or before the totals row/lastline. I get the following error on the code line 'Selection.EntireRow.Insert'
first "Run-time error '-2147417848 (80010108)':
Method 'Insert' of object 'Range' failed." When i run the debug and press F5 in VBE i get another error "Run-time error '1004' Insert method of Range class failed". Then Excel freezes and have to crash out.
I can't figure out the error, any help will be appreciated.
Many thanks
Kieranz

 
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
Run time error '4605' while copying excel range as picture in Wor Samirkc Excel Programming 0 July 27th 06 03:45 PM
Copying an entire row smitty24 Excel Programming 2 March 31st 06 05:16 AM
Copying entire row Sylvia[_11_] Excel Programming 1 January 12th 06 03:57 AM
copying entire column Charlie[_8_] Excel Programming 2 September 30th 04 12:50 PM
Macro for copying entire raw Mac[_5_] Excel Programming 3 November 13th 03 03:09 AM


All times are GMT +1. The time now is 03:37 PM.

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

About Us

"It's about Microsoft Excel"