Results 1 to 3 of 3

I can't figure out how to use code for two separate macros

Threaded View

  1. #1
    Forum Contributor
    Join Date
    02-14-2014
    Location
    Toronto, Canada
    MS-Off Ver
    Excel 2013
    Posts
    339

    I can't figure out how to use code for two separate macros

    I have a fairly extensive VBA code (75+ lines) that I would like to use in two different situations.

    The code for the second situation would be the same as the first except for a few additional lines of code.

    The first code uses a macro key combination (Ctrl-Shft-s) to call it.
    I would like to call the second code with its own macro key combination ((Ctrl-Shft-u).

    Ideally I would like to use the first macro's code and then jump to a second section to deal with the second situation.

    So here's the problem.
    How can I use the Ctrl-Shft-u to run the second macro, when I want to run the first code and then jump?

    Of course I know I can just copy all of the first code into the second macro, but I'm looking for a more efficient way to do this.

    TIA
    Last edited by ChrisXcel; 07-24-2014 at 09:59 PM. Reason: Fixed the title

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Vb macros code for sorting:
    By Dharani Suresh in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 08-14-2013, 02:29 AM
  2. [SOLVED] Run 3 macros with VB Code
    By rizmomin in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 03-24-2013, 01:40 PM
  3. Importing Excel Macros Code from another Excel sheet which has Macro code.
    By arun.pillai in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 01-14-2010, 05:38 PM
  4. Disable Macros From Within VBA Code?
    By Eric S. in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 05-04-2007, 10:36 AM
  5. macros or code
    By Neal in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 06-27-2005, 02:05 PM

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