Cut Paste r/t error 1004

jim may

Well-known Member
Joined
Jul 4, 2004
Messages
7,486
If I had a nickel (remember those?) for EVERY TIME I got a R/T error 1004 using the VBA Copy/Cut Paste procedure
I could retire in the Cayman Islands tomorrow

I'd love to find a teaching source that would clear up everything I seem to do to get these probs...

Why, if you can tell, is it that I'm getting the 1004 error on line 2 of some extracted code below..


Code:
Target.Cut
Target.Offset(5).PasteSpecial Paste:=xlPasteValues
 

Excel Facts

Difference between two dates
Secret function! Use =DATEDIF(A2,B2,"Y")&" years"&=DATEDIF(A2,B2,"YM")&" months"&=DATEDIF(A2,B2,"MD")&" days"
I guess you checked but what does Target. return

Don't use nickels in the UK
 
Upvote 0
Of course the target is a range (Mine being ONLY one cell "M2" - With the content text: "Double-Click Here."

I just want to move the text from my cell "M2" to "M7". Seems simple enough..
 
Last edited:
Upvote 0
i'm not sure, but doesn't it require a row AND column value ? even if that is 0, maybe it can be just done with a comma
 
Upvote 0
maybe it can be just done with a comma,,,
Huh; not sure what you mean here...
Can you be more specific? Tks for your help!!
Jim
 
Upvote 0
You can not cut and paste special

Can be

Code:
        Target.Cut
        Target.Offset(5, 0).Select
        ActiveSheet.Paste

Or

Code:
        Target.Copy
        Target.Offset(5, 0).PasteSpecial xlPasteValues
        Target.Clear
 
Upvote 0
I'm glad to help you. Thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,181
Members
453,022
Latest member
Mohamed Magdi Tawfiq Emam

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top