JoeyGaspard
Board Regular
- Joined
- Jul 22, 2019
- Messages
- 147
Hi all, with some of the members help, I was able to create a worksheet that does exactly what I need, so thanks to all that helped! Now, my problem is, every time I run the macro, my file size increases dramatically! how can I fix this? the code is below, it is a compilation for several different functions:
TIA for any help!
VBA Code:
Sub PasteSpecial_ValuesOnly()
'Clear UploadData Cells
Worksheets("PayrollData").Select
Range("A2:F50").Select
Selection.ClearContents
'Import Payroll Data
Dim Ws As Worksheet
Set Ws = Worksheets("PayrollData")
With Worksheets("PayrollReportImport")
.Range("A1").AutoFilter 1, "12-*"
.AutoFilter.Range.Offset(1).EntireRow.Copy Ws.Range("A" & Rows.Count).End(xlUp).Offset(1)
.AutoFilterMode = False
End With
'ClearGeneralJournal Macro
Worksheets("GeneralJournal").Select
Range("B17:eek:54").Select
Selection.Clear
'Copy A Range of Data
Worksheets("UploadData").Range("A2:M21").Copy
'PasteSpecial Values Only
Worksheets("GeneralJournal").Range("B17").PasteSpecial Paste:=xlPasteValues
'Clear Clipboard
Application.CutCopyMode = False
'Deletes blank rows if cells in Column B are empty
On Error Resume Next
Worksheets("GeneralJournal").Select
Range("B17:B54").Select
Selection.SpecialCells(xlCellTypeBlanks).EntireRow.Delete
Range("B17").Select
End Sub
TIA for any help!
Last edited by a moderator: