Running a method in BackGroundWorker and Showing ProgressBar

前端 未结 3 1676
南笙
南笙 2020-11-27 20:44

What I want is when some method is doing some task UI keeps itself active and I want to show the progress of the work in a progress-bar.

I have a method, a Bac

3条回答
  •  清酒与你
    2020-11-27 21:02

    I am sorry about the question. Actually the code works fine. It was not showing the Progressbar as the argument in myBGWorker.ReportProgress() was fraction and not percentage. So, it was not showing it. Sorry for the inconvenience.

    Moderator may delete this thread. Otherwise it can be a tutorial for others.

提交回复
热议问题