K
Kieranz
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
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