macro coding for a copy and paste

Toaster-Roaster

New Member
Joined
Sep 23, 2010
Messages
20
im tring to create a macro button which pastes my selected copied section to a certain column. once one has been pasted it will then paste to the row below e.t.c
 

Excel Facts

Pivot Table Drill Down
Double-click any number in a pivot table to create a new report showing all detail rows that make up that number
Toaster-Roaster,

Something like this?
Code:
Sub Button1_Click()
    
    Const DestCol As String = "A"
    Selection.Copy Cells(Rows.Count, DestCol).End(xlUp).Offset(1, 0)
    
End Sub



Hope that helps,
~tigeravatar
 
Upvote 0
this didnt work unfortunately, this section had an error to do with the wrong number of arguments or invalid property assignment "Selection.Copy Cells(Rows.Count, DestCol).End(xlUp).Offset(1, 0)"


i was going to use it so i can reference things easily and copy a website link and then paste each link under the other in column e from row 3
 
Upvote 0

Forum statistics

Threads
1,224,503
Messages
6,179,134
Members
452,890
Latest member
Nikhil Ramesh

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