Vbalearner85
Board Regular
- Joined
- Jun 9, 2019
- Messages
- 139
- Office Version
- 2016
- Platform
- Windows
I have below macro to run for file "Data.xlsm" to copy data from sheet "Cdata" to "Ddata". I want this code to run without going to the sheets (to not show the vba actions)..but it is not working..Any suggestions as to how to make it happen ..so that I can work on some other tab in the same workbook..along with macro ruining in the background.
Sub Ddata()
Application.ScreenUpdating = False
Sheets("CData").Range("A2:M142").Copy
Sheets("Ddata").Activate
Dim lastrow As Long
lastrow = Range("A1048576").End(xlUp).Row
Cells(lastrow + 1, 1).PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks:=False, Transpose:=False
End Sub
Sub Ddata()
Application.ScreenUpdating = False
Sheets("CData").Range("A2:M142").Copy
Sheets("Ddata").Activate
Dim lastrow As Long
lastrow = Range("A1048576").End(xlUp).Row
Cells(lastrow + 1, 1).PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks:=False, Transpose:=False
End Sub