+ Reply to Thread
Results 1 to 9 of 9

VBA Status Bar Message

  1. #1
    Forum Contributor
    Join Date
    05-26-2012
    Location
    United Kingdom
    MS-Off Ver
    Excel 2013
    Posts
    682

    VBA Status Bar Message

    Hi, I wonder whether someone may be able to help me please.

    I've found a 'Status Bar' message here: http://www.vbaexpress.com/kb/getarticle.php?kb_id=993 which I'd like to implement into a Excel workbook I extract files within.

    Following the instructions I replaced

    Please Login or Register  to view this content.
    with my own code, so the full script looks like:

    Please Login or Register  to view this content.
    But the problem I've got is that the 'Countdown' and '% Completion' don't work and the macro constantly runs on a loop, so I've clearly done something wrong.

    I've spent sometime researching Do Loops but I just can't get my ahead around this, so I just wondered whether someone may be able to look at this please and let me know where I've gone wrong.

    Many thanks and kind regards

    Chris
    Last edited by hobbiton73; 04-23-2015 at 03:11 AM.

  2. #2
    Forum Contributor LokeshKumar's Avatar
    Join Date
    03-31-2015
    Location
    India
    MS-Off Ver
    All, mostly 2010 now..
    Posts
    471

    Re: VBA Status Bar Message

    Hey,
    I have just seen, I have not found any sub you are calling like this.
    Maybe it is not the complete code.....

    Please Login or Register  to view this content.
    Lokesh Kumar
    Stay Hungry.. Stay Foolish..
    _________________________________________________________
    Please Click STAR to Add Reputation if my/someone's answer helped!

  3. #3
    Forum Contributor
    Join Date
    05-26-2012
    Location
    United Kingdom
    MS-Off Ver
    Excel 2013
    Posts
    682

    Re: VBA Status Bar Message

    Hi @LokeshKumar, thank you for taking the time to come back to me with this. As per the note in the code which I posted, this is my script which I'm trying to incorporate. My apologies for not making this clear.

    Kind Regards

    Chris

  4. #4
    Forum Contributor LokeshKumar's Avatar
    Join Date
    03-31-2015
    Location
    India
    MS-Off Ver
    All, mostly 2010 now..
    Posts
    471

    Re: VBA Status Bar Message

    If you upload the workbook with the code.....and what kind of error you are getting.....that would be so helpful for me...

  5. #5
    Forum Contributor
    Join Date
    05-26-2012
    Location
    United Kingdom
    MS-Off Ver
    Excel 2013
    Posts
    682

    Re: VBA Status Bar Message

    Hi when I upload the original file from the website link, the code works perfectly without any error.

    When I then intergrate my code into this the 'Status Bar' message is "Processing 17%" the whole script runs, then the script starts again with the 'Status Bar' message showing "Processing 33%", and it continues like this increaing the "Processing" % by 17% each time, so it's clearly something wrong with the loop. But I don't receive any error message.

    Many thanks and kind regards

    Chris

  6. #6
    Forum Guru Kyle123's Avatar
    Join Date
    03-10-2010
    Location
    Leeds
    MS-Off Ver
    365 Win 11
    Posts
    7,239

    Re: VBA Status Bar Message

    You're trying to run your code 600 times, that's why it goes on forever.

    In summary, you can't really use a progress meter without a loop since you have nothing to increment it with, your best bet for something like this would be :

    Please Login or Register  to view this content.
    And skip all the loop stuff

  7. #7
    Forum Contributor
    Join Date
    05-26-2012
    Location
    United Kingdom
    MS-Off Ver
    Excel 2013
    Posts
    682

    Re: VBA Status Bar Message

    Hi @Kyle123, thank you for taking the time to reply to my post. Yes I'd realised through the testing I'd one that the loop was needed, but it was a question of trying to implement this with my existing script, because I was keen in reproducing the format of the example I'd found.

    Many thanks and regards

    Chris

  8. #8
    Forum Guru Kyle123's Avatar
    Join Date
    03-10-2010
    Location
    Leeds
    MS-Off Ver
    365 Win 11
    Posts
    7,239

    Re: VBA Status Bar Message

    Unfortunately you can't since your code doesn't have a loop, unless it's in the subs you call - in which case you could put it there.

    TBH I'd look at making your code faster, there doesn't seem to be anything there that warrants a progress bar

  9. #9
    Forum Contributor
    Join Date
    05-26-2012
    Location
    United Kingdom
    MS-Off Ver
    Excel 2013
    Posts
    682

    Re: VBA Status Bar Message

    Ok, thank you for your help.

    Kind regards

    Chris

+ 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. status bar not showing the message
    By bezbid in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 02-03-2015, 12:59 AM
  2. [SOLVED] VBA Status Bar Message
    By hobbiton73 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 11-20-2014, 08:16 AM
  3. [SOLVED] How create status message
    By martinpaiva in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 05-28-2014, 11:10 AM
  4. Adding status bar message
    By me_king in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 05-05-2012, 05:37 PM
  5. calculate message in status bar
    By neda5 in forum Excel General
    Replies: 3
    Last Post: 04-11-2006, 01:10 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