+ Reply to Thread
Results 1 to 4 of 4

Program running 4 times instead of once, Work around?

  1. #1
    Registered User
    Join Date
    07-18-2013
    Location
    Denver, CO
    MS-Off Ver
    Excel 2013
    Posts
    4

    Program running 4 times instead of once, Work around?

    Hi Guys, I'm new to the forum so please excuse me if I mess anything up.

    I'm wondering how to get a certain program to only run once? The following code continues to loop 4 times which is a nuisance due to various pop up msgboxs. Any ideas?

    Please Login or Register  to view this content.
    The second issue is that each time the user updates any of the radio buttons, the program will re perform all the calculations. Is there any way to ignore certain button selections in the worksheet_change sub?

    Thanks in advance.
    -Myles

  2. #2
    Registered User
    Join Date
    07-18-2013
    Location
    Denver, CO
    MS-Off Ver
    Excel 2013
    Posts
    4

    Re: Program running 4 times instead of once, Work around?

    BUMP, Anyone? Is there not enough info?

  3. #3
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643

    Re: Program running 4 times instead of once, Work around?

    Myles

    I don't think you've posted all the code.

    In what you have posted other subs are being called, and those subs call other subs.

    There could be code in any of those subs that is changing the worksheet, and therefore triggering the change event.

    If that is the problem what you could do is add this in the Change event just before you call the other subs.
    Please Login or Register  to view this content.
    If you do use that it's important to enable events again:
    Please Login or Register  to view this content.
    If posting code please use code tags, see here.

  4. #4
    Registered User
    Join Date
    07-18-2013
    Location
    Denver, CO
    MS-Off Ver
    Excel 2013
    Posts
    4

    Re: Program running 4 times instead of once, Work around?

    Thank you very much, I was able to use the enableevents to get it to correctly run the first time, but if user updates after the initial run, noting happens. Am I using this correctly?

    Here is what I have so far:


    Please Login or Register  to view this content.
    Thank you very very much for the help!
    -Myles

+ 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. vba program - before and after times
    By quaye28 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-13-2011, 09:02 PM
  2. Excel VBA program times out
    By Zoomer36 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 09-21-2011, 12:49 PM
  3. Button program macro (times a pct)
    By rbpd5015 in forum Excel General
    Replies: 1
    Last Post: 08-03-2010, 07:09 PM
  4. program running too slow
    By gonger in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-03-2006, 11:56 AM
  5. how do i program excel to add two times together
    By adam in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 01-04-2006, 04:20 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