Hello all,
Need some help figuring this out. I am trying to create a macro to search a specific column for any text value and it copy it. I have the copy/paste part down, I need a way to have it search the column for any text. Text values vary by school names and they can change.
Thank you
Sub CopyDeployed()
a = Worksheets("Master").Cells(Rows.Count, 1).End(xlUp).Row
For i = 2 To a
If Worksheets("Master").Cells(i, 18).Value = 'this is where I need help' Then
Worksheets("Master").Rows(i).Copy
Worksheets("Deployed").Activate
b = Worksheets("Deployed").Cells(Rows.Count, 1).End(xlUp).Row
Worksheets("Deployed").Cells(b + 1, 1).Select
ActiveSheet.Paste
Worksheets("Master").Activate
End If
Next
End Sub
Need some help figuring this out. I am trying to create a macro to search a specific column for any text value and it copy it. I have the copy/paste part down, I need a way to have it search the column for any text. Text values vary by school names and they can change.
Thank you
Sub CopyDeployed()
a = Worksheets("Master").Cells(Rows.Count, 1).End(xlUp).Row
For i = 2 To a
If Worksheets("Master").Cells(i, 18).Value = 'this is where I need help' Then
Worksheets("Master").Rows(i).Copy
Worksheets("Deployed").Activate
b = Worksheets("Deployed").Cells(Rows.Count, 1).End(xlUp).Row
Worksheets("Deployed").Cells(b + 1, 1).Select
ActiveSheet.Paste
Worksheets("Master").Activate
End If
Next
End Sub