+ Reply to Thread
Results 1 to 4 of 4

Goto Macro - Active Worksheet

  1. #1
    Registered User
    Join Date
    08-17-2015
    Location
    Bristol
    MS-Off Ver
    2007
    Posts
    1

    Goto Macro - Active Worksheet

    Hi, hope somebody can help. I have the following code, attached to a macro button but it only seems to work in one worksheet. can somebody help and suggest what I need, so that it works on the active sheet and not throw up an error. thank you.

    Please Login or Register  to view this content.

  2. #2
    Forum Expert
    Join Date
    04-23-2009
    Location
    Matrouh, Egypt
    MS-Off Ver
    Excel 2013
    Posts
    6,882

    Re: Goto Macro - Active Worksheet

    The code is working for any active sheet .. But the error may be occurs because of not finding the text that you are searching for
    You can add a line to avoid errors at the start of the code
    Please Login or Register  to view this content.
    < ----- Please click the little star * next to add reputation if my post helps you
    Visit Forum : From Here

  3. #3
    Forum Moderator davesexcel's Avatar
    Join Date
    02-19-2006
    Location
    Regina
    MS-Off Ver
    MS 365
    Posts
    13,482

    Re: Goto Macro - Active Worksheet

    What's the error you are getting?

  4. #4
    Forum Guru bakerman2's Avatar
    Join Date
    10-03-2012
    Location
    Antwerp, Belgium
    MS-Off Ver
    MO Prof Plus 2016
    Posts
    6,908

    Re: Goto Macro - Active Worksheet

    How about this ?

    Please Login or Register  to view this content.
    Avoid using Select, Selection and Activate in your code. Use With ... End With instead.
    You can show your appreciation for those that have helped you by clicking the * at the bottom left of any of their posts.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Macro for Active Worksheet
    By RosieW in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 08-17-2017, 05:34 AM
  2. Macro to export active worksheet as a pdf with "fit all rows on one page" active
    By NickyHavey in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 06-06-2016, 11:06 AM
  3. Macro - to only run on active worksheet
    By ChocksterNo1 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 05-21-2013, 11:48 AM
  4. [SOLVED] Use Template Worksheet and VBA to add a new worksheet to active non macro workbook
    By fbplaya02 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 04-30-2013, 01:34 AM
  5. Macro to edit active chart on active worksheet
    By shlurpee in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 05-07-2011, 04:58 AM
  6. Macro to goto appropriate worksheet
    By rockycj in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 03-13-2008, 05:30 PM
  7. [SOLVED] Goto a named range using the contents of the active cell
    By Brian C in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-14-2006, 12:14 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1