Home |
Search |
Today's Posts |
#1
![]() |
|||
|
|||
![]()
I am running excel2002 on Windows xp and dabbling in the writing of macros.
Can anyone tell me what is wrong with this? 'rem Copy the duplicated record to Archive and delete Dim delcell As Range Dim myRange As Range Dim copyToRange As Range Set copyToRange = Range("Archive!C12") Set myRange = Range("dup") Set delcell = myRange.Find(What:=1, LookIn:=xlValues, LookAt:=xlWhole) If Not delcell Is Nothing Then With delcell.EntireRow Intersect(.Cells, Range("C:DC")).Copy Destination@ = copyToRange .Delete End With End If I get the following error message at the line that begins "Intersect..." Run Time Error '1004' Copy method of Range class failed. Any help gratefully received Dave Moore |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
I get wrong dates when i paste from a different sheet into a new s | Excel Discussion (Misc queries) | |||
Subtotal of Subtotal displays Grand Total in wrong row | Excel Worksheet Functions | |||
multi-level subtotals are in the wrong position | Excel Worksheet Functions | |||
Logic statement returns wrong answer. | Excel Worksheet Functions | |||
IF function displays wrong amount | Excel Worksheet Functions |