View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 27,285
Default How to make a sheet the active sheet?

worksheets("sheet2").Activate


or
Application.Goto Reference:=Worksheets("Sheet2").Range("A1")



or you can just refer to Sheet2 and not make it the active sheet

With Worksheets("Sheet2")
.Range("A1").Value = 7
.Range("A1:A10").Interior.ColorIndex = 5
End with

as an example.

--
Regards,
Tom Ogilvy

wrote in message
...
If the user is on sheet 3, and I want the macro to be applied to sheet
2, how can I get the macro to make sheet 2 the active sheet?

tia