Excel/Macro for CUT and PASTE VALUE
My sorry for the last question, i have expressed me wrong.
I need a macro that makes the CUT can be pasted in value.
Copy i know thats work but i dont know how to CUT and PASTE in value.
Can you help me with that?
to do a cut and paste, you select a range, cut, select another range and then paste.
in code you can make the source variable, but you need to already know the destination.
As you already state, you can't pastespecial manually with a cut. So to do what you describe, you need to copy, do a pastespecial, then clear what you copied.
to do what you describe this code works, but the destination is already specified
Dim r as range
set r = selection
So what we are missing is an ability to specify where to paste special. You could add code to allow you to prompt for the destination. You can use the mouse to select the destination cell.
Dim r As Range, rDest As Range
Set r = Selection
On Error Resume Next
Set rDest = Application.InputBox("Select one cell to paste to: ", Type:=8)
Set rDest = rDest(1)
On Error GoTo 0
If rDest Is Nothing Then
MsgBox "No destination selected."
Application.CutCopyMode = False
That is about the best I can offer. I tested it an it worked as I expect.
This topic answers questions related to Microsoft Excel spreadsheet (or workbook) stand-alone or Mircrosoft Office Excel including Excel 2003, Excel 2007, Office 2000, and Office XP. You can get Excel help on Excel formulas(or functions), Excell macros, charting in Excel, advanced features, and the general use of Excel. This does not provide a general Excel tutorial nor the basics of using a spreadsheet. It provides specific answers to using Microsoft Excel only. If you do not see your Excel question answered in this area then please ask an Excel question here