I have a code that I used in a different macro and wotked that now is not working and I keep getting run time error 1004 in the line with activate:
Sub initialize()
dim MonthName as string
dim MainWB as workbook
dim VisualWS as worksheet
MonthName = cells (1,1).value
Set MainWB = ThisWorkbook
Set VisualWS = MainWB.Worksheets("Visual")
With VisualWS
.Range("L1:W1").Find(MonthName, , xlValues, xlWhole).Activate
End With
MonthCol = ActiveCell.Column
End Sub