Cut Copy Paste Option

Closed
smuneeb Posts 67 Registration date Saturday September 5, 2015 Status Member Last seen March 8, 2017 - Nov 8, 2015 at 07:30 AM
smuneeb Posts 67 Registration date Saturday September 5, 2015 Status Member Last seen March 8, 2017 - Nov 9, 2015 at 04:37 PM
Hello,

I would like to request if user copy data from "ExcFileB" Sheet1 to "ExcFileA" Sheet1
then it always Pasted as Values.
Is this possible in Module
I need that because I made a specific design for table in ExcFileA Sheet1 and also containing VB Code
User always copy data from ExcFileB Sheet1 to ExcFileA Sheet1 and paste it.
Since it is instructed that always Pasted as Values but some were follow and some don't follow
If user just pasted then it will changes the design of Table which is done in ExcFileA Sheet1 and
also VB Code is not working properly. (After saving and open that file then it works)
Please don't consider FileName as any Entity because File Name changes many time. It is only for sample.
Please consider copy action from memory or clipboard so it may be no need to assign any entity to File Name.
because Selection area could be different for copying
Pasting area is specified i.e. B2 to D1000
Thanks


1 response

rizvisa1 Posts 4478 Registration date Thursday January 28, 2010 Status Contributor Last seen May 5, 2022 766
Nov 9, 2015 at 09:41 AM
you can use macro recorder to create a template macro
0
smuneeb Posts 67 Registration date Saturday September 5, 2015 Status Member Last seen March 8, 2017 1
Nov 9, 2015 at 12:41 PM
Thanks for Informing but will you help me to solve it or create it.
0
rizvisa1 Posts 4478 Registration date Thursday January 28, 2010 Status Contributor Last seen May 5, 2022 766 > smuneeb Posts 67 Registration date Saturday September 5, 2015 Status Member Last seen March 8, 2017
Nov 9, 2015 at 12:45 PM
I am trying to help you in solving your issue. Paste your template macro and i would then be able to help. In case you are not aware, macro recorder is use to record you actions and create a macro that can then be customized to make it more suitable.
0
smuneeb Posts 67 Registration date Saturday September 5, 2015 Status Member Last seen March 8, 2017 1 > rizvisa1 Posts 4478 Registration date Thursday January 28, 2010 Status Contributor Last seen May 5, 2022
Nov 9, 2015 at 01:21 PM
Hi
Sorry if I don't understand your point.
You are saying that How to record the Macro if Yes then for this I recorded the Macro
where it doesn't have a code

Sub PasteAsValues()
'
' PasteAsValues Macro
' Macro will run to pasted as Values
'

'
End Sub

Thanks again and also apologies If I don't understand
0
smuneeb Posts 67 Registration date Saturday September 5, 2015 Status Member Last seen March 8, 2017 1 > rizvisa1 Posts 4478 Registration date Thursday January 28, 2010 Status Contributor Last seen May 5, 2022
Nov 9, 2015 at 04:37 PM
This is the code for Record Macro

Sub PasteAsValues()
'
' PasteAsValues Macro
' Macro will run to pasted as Values
'
Range("A:A").Select
Selection.Copy
Range("B:B").Select
ActiveSheet.PasteAsValues

Application.CutCopyMode = False


'
End Sub

but what I need if user copy from any workbook sheet where ever he pasted in another workbook sheet always pasted as values.

Thanks
0