I have two worksheets and want to
1) select a cell in sheet 1 (cell may change with each search),
2) copy that value,
3) search for the value in the other sheet (filter)
4) copy the values returned and
5) place those values in a specific region in the first spreadsheet
I can do this manually in a macro, but I don't know how to pass a new cell value each time I run the macro in step 1. The value remains hardcoded to the initial value recorded. Do I have to ask the user to select the cell? But how do I capture in in the macro and use it?
The macro code:
Sub Macro9()
'
' Macro9 Macro
'
'
ActiveWindow.Panes(1).Activate
Range("E3").Select
Selection.Copy
With ActiveWindow
.Width = 933.75
.Height = 573.75
End With
Sheets("Sheet2").Select
ActiveSheet.Range("$A$1:$GH$1670").AutoFilter Field:=2, Criteria1:= _
"=DM Review", Operator:=xlAnd
Columns("B:O").Select
Application.CutCopyMode = False
Selection.Copy
Sheets("2008 Edit Cal Deadlines").Select
ActiveWindow.Panes(3).Activate
Range("A222").Select
ActiveSheet.Paste
End Sub
Thanks!
Bookmarks