tanyaleblanc
Board Regular
- Joined
- Mar 16, 2019
- Messages
- 145
Hi, I want to filter column J to move the data that has the words ACH Credit Received to the bottom of the page, beneath the other data that is on the sheet. For example, I have 18 lines of data, 8 lines are for ACH credit rec'd and I want to move these 8 lines to the bottom a few lines after the last row in my list of data. I want to move this data to row 24 (this will change as each day the number of rows changes, but ultimately I just want this data to appear at the bottom so I can total my two sets of data from column I when I'm finished separating the data.
My code is ok until I get to the Range("a2 & lrow").Select because I don't know how to move these line items to the end of the data by a couple rows.
Once I get these data separated, I want to sum the two sets of data from column I
My code is ok until I get to the Range("a2 & lrow").Select because I don't know how to move these line items to the end of the data by a couple rows.
VBA Code:
Sheets("Bank 7").Select
Rows("1:1").Select
Selection.AutoFilter
ActiveSheet.Range("$A$1:$AD$19").AutoFilter Field:=10, Criteria1:=Array( _
"ACH CREDIT RECEIVED", "TOTAL ACH CREDIT", "TOTAL ACH RELATED DEBITS"), Operator _
:=xlFilterValues
ActiveSheet.Range("$A$1:$AD$19").AutoFilter Field:=10, Criteria1:= _
"ACH CREDIT RECEIVED"
Range("a2 & lrow").Select
Range(Selection, Selection.End(xlDown)).Select
Selection.Copy
Row24.Activate .PasteSpecial Paste:=xlPasteValues
Once I get these data separated, I want to sum the two sets of data from column I
Code:
Range("H10").Select
Application.CutCopyMode = False
ActiveCell.FormulaR1C1 = "=SUM(R[-8]C:R[-1]C)"
Range("H24").Select
Application.CutCopyMode = False
ActiveCell.FormulaR1C1 = "=SUM(R[-10]C:R[-1]C)"
Range("G24").Select
ActiveCell.FormulaR1C1 = "IBP"
Columns("H:H").Select
Selection.NumberFormat = "#,##0.00"