+ Reply to Thread
Results 1 to 8 of 8

How to create a static progress bar that is fixed and responds to user input manually

  1. #1
    Forum Contributor
    Join Date
    06-07-2014
    Posts
    219

    How to create a static progress bar that is fixed and responds to user input manually

    The attached workbook opens a userform with three textboxes and three labels. I want to be able to enter a number from 1 to 100 in the textbox and the label should change from its fully grey color to the
    corresponding shade of yellow as per the number entered in the textbox. An example is in the picture below.

    staticbar.jpg

    Essentially the purpose is to have more or less a static progress bar, where one can update the number progress in the textbox and the label will update as a result and one can then use his code to save the
    data values in the usual way.

    Are you able to assist with the coding to update the label after the textbox value has been changed?

    Thanks!
    Attached Files Attached Files
    If you have received help from a user, please feel free to Rep that person.
    Also, do remember to click Thread Tools and mark your thread as solved, if you have achieved a solution to your thread.

  2. #2
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: How to create a static progress bar that is fixed and responds to user input manually

    Hi,

    Use the text box change event. e.g.

    Please Login or Register  to view this content.
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  3. #3
    Forum Expert Keebellah's Avatar
    Join Date
    01-12-2014
    Location
    The Netherlands
    MS-Off Ver
    Office 2021 (Windows)
    Posts
    7,937

    Re: How to create a static progress bar that is fixed and responds to user input manually

    Or try this
    I set the imax to 100 in the userfrom's vba
    Attached Files Attached Files
    ---
    Hans
    "IT" Always crosses your path!
    May the (vba) code be with you... if it isn't; start debugging!
    If you like my answer, Click the * below to say thank-you

  4. #4
    Forum Contributor
    Join Date
    06-07-2014
    Posts
    219

    Re: How to create a static progress bar that is fixed and responds to user input manually

    Thanks Richard Buttrey and Hans; both are simply amazing solutions!

    Hans, any chance for there to be no progress showing at 0%? I ask because at zero there is a little small red bar present under the 0%.

  5. #5
    Forum Expert Keebellah's Avatar
    Join Date
    01-12-2014
    Location
    The Netherlands
    MS-Off Ver
    Office 2021 (Windows)
    Posts
    7,937

    Re: How to create a static progress bar that is fixed and responds to user input manually

    You can cahnge the label width to 0 or add the follwoing code the userform's VBA

    Please Login or Register  to view this content.

  6. #6
    Forum Contributor
    Join Date
    06-07-2014
    Posts
    219

    Re: How to create a static progress bar that is fixed and responds to user input manually

    Quote Originally Posted by Keebellah View Post
    You can cahnge the label width to 0 or add the follwoing code the userform's VBA

    Please Login or Register  to view this content.
    Very well! Great solutions from great minds!

  7. #7
    Forum Expert Keebellah's Avatar
    Join Date
    01-12-2014
    Location
    The Netherlands
    MS-Off Ver
    Office 2021 (Windows)
    Posts
    7,937

    Re: How to create a static progress bar that is fixed and responds to user input manually

    Just some fine tuning
    Attached Files Attached Files

  8. #8
    Forum Contributor
    Join Date
    06-07-2014
    Posts
    219

    Re: How to create a static progress bar that is fixed and responds to user input manually

    Quote Originally Posted by Keebellah View Post
    Just some fine tuning
    Good adjustments

    Thanks.

+ 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. create user input for private sub
    By ammartino44 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 08-07-2015, 01:56 AM
  2. Amendments to exisitng macro to manually input agent user names
    By DancingElvis in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-02-2013, 05:05 PM
  3. Convert freeform user input and write to a fixed length text file
    By vijaymohan10 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 07-02-2013, 04:44 AM
  4. [SOLVED] Macro to manually input which field (column) to autofilter on using an input prompt
    By rin in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 06-21-2012, 09:35 AM
  5. Replies: 2
    Last Post: 11-22-2011, 12:33 PM
  6. Manually add fixed vertical horizontal line to chart
    By datacruncher in forum Excel Charting & Pivots
    Replies: 3
    Last Post: 12-21-2009, 08:33 AM
  7. How to create a User input dialog box?
    By gshock in forum Excel Programming / VBA / Macros
    Replies: 14
    Last Post: 11-14-2008, 01:21 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