quitethenovice
New Member
- Joined
- Jun 3, 2020
- Messages
- 12
- Office Version
- 365
Hello my friends
I'm still quite new to VBA and im trying to use array to sort my large Sheet1 quickly rather than normal autofilter. Could you help me with how I move the data into the output array and in the order I have listed.
Your community guidance valued.
I'm still quite new to VBA and im trying to use array to sort my large Sheet1 quickly rather than normal autofilter. Could you help me with how I move the data into the output array and in the order I have listed.
Your community guidance valued.
VBA Code:
Dim Input as Variant, Output As Variant
Dim ArrIN As Variant, ArrOUT As Variant, LastRow As Long, x As Long, y As Long
LastRow = Sheets("Sheet1").Range("A" & Rows.Count).End(xlUp).Row
Input = Sheets("Sheet1").Range("A2:T" & LR1).Value
ReDim Output(1 To LastRow, 1 To 10)
x = 1
For x = LBound(Input) To UBound(Input)
If Input(x, 3) > 0 And Input(x, 6) <> "" And Input(x, 8) Like "*Free*" Then
End If
'Output Columns in order 5,6.7,1,2,3,8,9,10,3,4
Sheets("Sheet2)".Range("A2:J2").Resize(UBound(Ouput)).Value = Output