Macro for Pasting Values

Markymark123

New Member
Joined
Oct 20, 2006
Messages
12
Hi,

Can someone tell me what the Macro would be for pasting values?

I use this function all time and would like to have a macro for it.

Also I've tried to use the recorder fcn but it's not working either.

Thx
 

Excel Facts

How can you automate Excel?
Press Alt+F11 from Windows Excel to open the Visual Basic for Applications (VBA) editor.

Smitty

Legend
Joined
May 15, 2003
Messages
29,536
Welcome to the Board!

You can use pasteValues:

<font face=Tahoma><SPAN style="color:#00007F">Sub</SPAN> Macro1()
    <SPAN style="color:#00007F">With</SPAN> Selection
        .Copy
        .PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
            :=False, Transpose:=<SPAN style="color:#00007F">False</SPAN>
    <SPAN style="color:#00007F">End</SPAN> <SPAN style="color:#00007F">With</SPAN>
    Application.CutCopyMode = False
<SPAN style="color:#00007F">End</SPAN> <SPAN style="color:#00007F">Sub</SPAN></FONT>

HTH,

Smitty
 

Marc

Active Member
Joined
Feb 21, 2002
Messages
388
Another way to accomplish this without a macro is to customize your toolbar.

1. Right Click the toolbar.
2. Choose Customize.
3. Choose the 'Commands' tab.
4. In the Categories box select 'Edit'.
5. In the Commands box scroll down until you see 'Paste Values'.
6. Drag it up to your toolbar.
 

Forum statistics

Threads
1,136,925
Messages
5,678,601
Members
419,774
Latest member
MooseWinooski

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
Top