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 6334007
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T18:34:34+00:00 2026-05-24T18:34:34+00:00

I have a progressbar on my form that is not getting updated. When the

  • 0

I have a progressbar on my form that is not getting updated.

When the Send Email button is clicked I do this:

Public Sub SendMail()
    If CheckSettings() = False Then Exit Sub
    BackUpEbillFile()
    LockForm(True)
    StatusBars(1, "Sending emails...")
    ProgressBar1.Maximum = intInvoicesToSend  
    BackgroundWorker1.RunWorkerAsync()
End Sub

I have the following events:

Private Sub BackgroundWorker1_DoWork(sender As Object, e As System.ComponentModel.DoWorkEventArgs) Handles BackgroundWorker1.DoWork
    e.Result = SendBills()
End Sub

Private Sub BackgroundWorker1_ProgressChanged(sender As Object, e As System.ComponentModel.ProgressChangedEventArgs) Handles BackgroundWorker1.ProgressChanged
    Console.WriteLine("I DID IT MA!!!!1 status: " & ProgressBar1.Value)
    ProgressBar1.PerformStep()
    Console.WriteLine("I DID IT MA!!!!2 status: " & ProgressBar1.Value)
End Sub

In the SendBills, which is in a mail class, I do this:

smtp.Send(msg)
Console.WriteLine("I DID IT PA!!!! count: " & iCount)
frmBilling.BackgroundWorker1.ReportProgress(iCount)

My problem lies at the ProgressBar1.PerformStep() in the ProgressChanged. I am getting to the progress changed but the Progressbar1 is not changing. It stays at zero.

  • intInvoicesToSend is 16
  • ProgressBar1.Minimum = 0
  • ProgressBar1.Maximum = intInvoicesToSend (which was 16)
  • ProgressBar1.Step = 1

Here is my console from the console.writelines:

I DID IT PA!!!! count: 0

I DID IT MA!!!!1 status: 0

I DID IT MA!!!!2 status: 1

I DID IT PA!!!! count: 1

I DID IT MA!!!!1 status: 1

I DID IT MA!!!!2 status: 2

I DID IT PA!!!! count: 2

I DID IT MA!!!!1 status: 2

I DID IT MA!!!!2 status: 3

I DID IT PA!!!! count: 3

I DID IT MA!!!!1 status: 3

I DID IT MA!!!!2 status: 4

Can anyone tell me what I’m doing wrong?
Thanks!

  • 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-24T18:34:35+00:00Added an answer on May 24, 2026 at 6:34 pm

    My suspicion is that you’re calling the ReportProgress method on the wrong instance.

    See this line:

    frmBilling.BackgroundWorker1.ReportProgress(iCount)
    

    If the BackgroundWorker is defined directly within your form, you can leave off the frmBilling portion, and just specify this as:

    BackgroundWorker1.ReportProgress(iCount)
    

    The way you have it may be causing the ReportProgress to get called on the wrong instance…

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a form that has several controls: ProgressBar at the top of the
I have a form with a progress bar and a cancel button which is
I have a ProgressBar that uses the marquee style when a report is being
I'm working an a form with a progressbar, which is meant to have certain
I have a windows form application that needs to load a bunch of things
Scenario : What I have is an upload form that reports on the upload
I have a form that is loading quite an amount of data from SQL
I have a function that simply fills a progress bar. private void FillProgressBar(ProgressBar bar,
I have an upload form that should display a progress bar while the file
I have a base form that I use when calling 2 forms. Previously when

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.