+ Reply to Thread
Results 1 to 6 of 6

Is it possible to pause a macro with a button on the worksheet?

  1. #1
    Registered User
    Join Date
    05-30-2014
    Location
    Lima, Peru
    Posts
    31

    Is it possible to pause a macro with a button on the worksheet?

    Hi,
    Question.
    Is there a way to create a button for the macro that would allow me to pause it and enter data in other cells, without having to go into the VB code and pause it there?
    This is the code on the sheet:
    Please Login or Register  to view this content.
    This is the macro part:
    Please Login or Register  to view this content.
    Today, I found that I need to expand where I enter expenditures, but in order to do so, I have to open VB to pause the macro for the tab order.
    Any help with this would be greatly appreciated.

    Best Regards,
    gfc
    Last edited by Mr.GfCs; 05-05-2015 at 07:36 PM. Reason: Issue Resolved

  2. #2
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS365 Family 64-bit
    Posts
    24,720

    Re: Is it possible to pause a macro with a button on the worksheet?

    Pausing the code in the VBA window is a debugging feature, not the normal way to run VBA. You can add a button that will simply pause code by showing a userform that waits to resume until you click a button, but you won't be able to do anything on a worksheet while it's paused. There might be a way to do this but I suspect we can get you a better solution if you explain a little more about what you need to do.

    ...pause the macro for the tab order.
    What does that mean? What do you need to do on your worksheet while the macro is still running? How does tab order come into play? Also, where is Auto_Open being called from?
    Jeff
    | | |會 |會 |會 |會 | |:| | |會 |會
    Read the rules
    Use code tags to [code]enclose your code![/code]

  3. #3
    Registered User
    Join Date
    05-30-2014
    Location
    Lima, Peru
    Posts
    31

    Re: Is it possible to pause a macro with a button on the worksheet?

    I'm not sure how to answer part of what you asked, so I uploaded the spreadsheet.

    Basically, in the box that has the double red boarder-lines, I'm wanting to be able to utilize them, without using the 'tab order' macro that runs when the sheet is opened.
    I'd like to be able to click on a button, that turns the Tab-macro off, without having to open vb and pause it.

    Thanks,
    gfc
    Attached Files Attached Files

  4. #4
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS365 Family 64-bit
    Posts
    24,720

    Re: Is it possible to pause a macro with a button on the worksheet?

    We normally recommend that you don't start by describing a solution, but rather describe the problem you need to solve. You don't want to pause the macro, you want to be able to edit cells in F16:K34 without the macro repositioning the selection. Doing this by creating a Pause button and pausing the macro is much too complicated. Try adding the red line to your code:

    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    05-30-2014
    Location
    Lima, Peru
    Posts
    31

    Re: Is it possible to pause a macro with a button on the worksheet?

    Thank you very much. This resolved the problem.
    While I am familiar with excel, I am afraid that my familiarity with it, is just enough to get myself in a pickle sometimes. I appreciate your help, as well as your 'schooling me' in how to make the post correctly. As in the tittle.

    I really appreciate the help I have been given on this spreadsheet, as I have to start keeping track of my expenses. I find that as I am getting older, I'm at a loss as to where it's all going.

    Thank you again for the help.

    Best Regards,
    gfc

  6. #6
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS365 Family 64-bit
    Posts
    24,720

    Re: Is it possible to pause a macro with a button on the worksheet?

    Good luck. I used to use a spreadsheet to track expenses vs. a budget, balance my checkbook, etc. I finally caved in and bought Quicken.

    The classic way to track expenses is to have a table--you already have that, right track!--and for each transaction, note who you paid, date, how much, and the category it falls into. You can then use Excel to create a pivot table to summarize your expenses by category, or other kinds of analysis. If you try your file for a while and find it isn't doing what you need, feel free to come back here for other ideas.

+ 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. Replies: 0
    Last Post: 06-24-2013, 04:24 PM
  2. Pause and resume button using VBA
    By kyod in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 10-08-2009, 08:36 AM
  3. Abort button for a macro(not the break key) and pause/resume button
    By c.vaibhav in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 05-21-2009, 04:22 AM
  4. Excel 2007 : Macro pause button
    By Terri_Galloway in forum Excel General
    Replies: 2
    Last Post: 02-11-2009, 12:45 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