?
Solved

Move to a different sheet based on cell "A3" of current sheet

Posted on 2011-03-18
1
Medium Priority
?
197 Views
Last Modified: 2012-05-11
I would like to change the following code so it works on every sheet in the workbook.  I know I can copy and paste it to each sheet, but I thought there might be a simpler way.

Thanks,
Joan
Private Sub Worksheet_Change(ByVal Target As Range)
On Error Resume Next
Application.EnableEvents = False
Application.ScreenUpdating = False

    If Target.Address = Range("A3").Address Then
        Application.GoTo Worksheets(Range("AC2").Value).Range("A3")
        
    End If
        
Application.EnableEvents = True
Application.ScreenUpdating = True

End Sub

Open in new window

0
Comment
Question by:jmkbrown
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 33

Accepted Solution

by:
jppinto earned 2000 total points
ID: 35165686
You can try putting this code on the Workbook Sheet_Change event:

Private Sub Workbook_SheetChange(ByVal Sh As Object, ByVal Target As Range)

     ' your code here...

End Sub
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article will guide you to convert a grid from a picture into Excel format using Microsoft OneNote and no other 3rd party application.
Access developers frequently have requirements to interact with Excel (import from or output to) in their applications.  You might be able to accomplish this with the TransferSpreadsheet and OutputTo methods, but in this series of articles I will di…
This Micro Tutorial will demonstrate in Microsoft Excel how to add style and sexy appeal to horizontal bar charts.
This Micro Tutorial will demonstrate how to create pivot charts out of a data set. I also added a drop-down menu which allows to choose from different categories in the data set and the chart will automatically update.

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question