Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6904145
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T08:00:57+00:00 2026-05-27T08:00:57+00:00

My question here is not how to create a single progress bar, but instead

  • 0

My question here is not how to create a single progress bar, but instead how to create a progress bar that keeps track and updates two different processes. For example within the same window I’d like to have a bar keeping track of the current simulation index and another bar keeping track of another series of numbers…my current code is:

library(tcltk2)

pb1 <- tkProgressBar(title = "Simulation Progress...", min = 1, max = 10, width = 300)
pb2 <- tkProgressBar(title = "Simulation Progress...", min = 2000, max = 2020, width = 300)

for (index in 1:10){

setTkProgressBar(pb1, index, label = paste("Index",index))

for (year in 2000:2020){

setTkProgressBar(pb2, year, label = paste("Year",year))

}

}

I’d like to have both bars together, not separate…any help appreciated!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T08:00:58+00:00Added an answer on May 27, 2026 at 8:00 am

    Not possible using tkProgressBar, you’ll have to dig down into the depth of tcltk, something like this:

    library(tcltk2)
    
    root <- tktoplevel()
    
    l1 <- tk2label(root,"Simulation Progress...")
    pb1 <- tk2progress(root, length = 300)
    tkconfigure(pb1, value=0, maximum=9)
    
    l2 <- tk2label(root, "Simulation Progress...")
    pb2 <- tk2progress(root, length = 300)
    tkconfigure(pb2, value=0, maximum=20, maximum = 20)
    
    tkpack(l1)
    tkpack(pb1)
    tkpack(l2)
    tkpack(pb2)
    
    tcl("update")
    
    for (index in 1:10){
    
        tkconfigure(l1, text = paste("Index", index))
        tkconfigure(pb1, value = index - 1)
    
        for (year in 2000:2020){
            tkconfigure(l2, text = paste("Year",year))
            tkconfigure(pb2, value = year - 2000)
    
    
        tcl("update")
        }       
    
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I see this question here on SO but I am not sure that answers
Related to my question here but not enough to open a new question. I
I'm not sure I'm asking the right question here, but I'm looking to provide
this is my first question here :) I know that I should not check
The question is closely related to my past question here, but it is not
Pretty simple but specific question here: I'm not entirely familiar with the JPEG standard
The question here is whether something like this already exists or, if not, whether
Actually my question here is: are null and nil equivalent or not? I have
I asked a question [ here ] recently and it's just not providing me
maybe it's not so proper to ask this question here... anyway, I'm trying to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.