Results 1 to 8 of 8

Msgbox is lethargic / slow!

Threaded View

  1. #1
    Registered User
    Join Date
    12-12-2018
    Location
    Virginia
    MS-Off Ver
    Windows x
    Posts
    5

    Msgbox is lethargic / slow!

    My msgbox and inputBox sometimes... SOMETIMES... gets really slow. There can be as much as a 5 or 6 second lag between key inputs. This problem is intermittent.

    I'm pretty advanced in my knowledge of VBA / Excel. I'm far from a beginner by any stretch of the imagination. I'm hoping someone reads this and know more about Excel's programming.

    What I've tried so far: When my VBA program runs, I start off with the typical 3 (screen updating off, calculation to manual, enable events off). I also have a debug log setup within my program to record where code the program is and at what time. These checkpoints are all over my code. That sub looks like this:

    Sub debugCheckpoint(subRoutine As String)
        Dim printLine As String, Bench As Double
        
        Call lethargicProgramCheck
        If ActiveWorkbook.Name <> "Master Listing.xlsb" Then End
        
        ThisWorkbook.checkpointCount = ThisWorkbook.checkpointCount + 1
        subRoutine = "[" & ThisWorkbook.checkpointCount & "];" & ThisWorkbook.subStack & "; " & subRoutine
        Application.CutCopyMode = False
        
        printLine = subRoutine & "; T+Start:;" & Round(Timer - ThisWorkbook.startTimer, 5)
        Open "I:\Text_and_Upload_Files\Text Files\ErrorLog.txt" For Append As #1
        Print #1, printLine
        Close #1
    End Sub

    My other sub looks something like this

        call debugCheckpoint("LocationX")
        Application.ScreenUpdating = True
        msgbox ("This is your message", vbYesNo)
        Application.ScreenUpdating = False
        call debugCheckpoint("LocationY")
    and my checkpoint text file records location x and y along with the long lag, but nothing in between.
    Last edited by jayplac; 01-12-2019 at 12:42 PM.

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Slow macro, slow pc or wrong code?
    By corky81 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 09-24-2018, 05:58 AM
  2. Macro to capture MsgBox prompt to a string variable but ignore the MsgBox
    By BuglerDobbs in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 05-07-2015, 10:56 AM
  3. Macro is running real slow and makes navigating the worksheet really slow after execution.
    By MichWolverines in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-03-2013, 04:29 PM
  4. [SOLVED] Problem with VBA Editor uses lower case on some lines (ex. msgbox instead of MsgBox)
    By stubbsj in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 09-14-2013, 06:59 PM
  5. [SOLVED] slow computer (slow clipboard) breaks my macro
    By twilsonco in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 06-05-2013, 09:16 PM
  6. Slow code msgbox yes no
    By D_Rennie in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-29-2009, 10:54 AM
  7. Excel seems to become lethargic
    By Paul987 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 07-22-2005, 11:05 PM

Tags for this Thread

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