473,326 Members | 2,134 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,326 software developers and data experts.

progressbar not displaying

Hi,

I have a progress bar that is instantiated on form_load.
Created this simple button to test the progress bar but nothing moves or shows.
visible is true.... And I cannot see anything wrong...
See code below:

private void button1_Click(object sender, System.EventArgs e)
{
pgProgress.TabIndex = 0;
pgProgress .Maximum =15;
pgProgress .Minimum =1;
pgProgress .Step =1;
for(int i=pgProgress.Minimum; i <= pgProgress.Maximum; i++)
{
pgProgress.PerformStep();
this.Refresh();
}
}

Any help would be greatly appreciated.
Nov 16 '05 #1
2 1190
Michaeld wrote:

Hi,

I have a progress bar that is instantiated on form_load.
Created this simple button to test the progress bar but nothing moves or shows.
visible is true.... And I cannot see anything wrong...
See code below:

private void button1_Click(object sender, System.EventArgs e)
{
pgProgress.TabIndex = 0;
pgProgress .Maximum =15;
pgProgress .Minimum =1;
pgProgress .Step =1;
for(int i=pgProgress.Minimum; i <= pgProgress.Maximum; i++)
{
pgProgress.PerformStep();
this.Refresh();
}
}

Any help would be greatly appreciated.


Try

pgProgress.Refresh();

or

pgProgress.Update();

instead.
Nov 16 '05 #2
You might try

DoEvents();

Gerrit

"Julie" <ju***@nospam.com> schreef in bericht
news:40**************@nospam.com...
Michaeld wrote:

Hi,

I have a progress bar that is instantiated on form_load.
Created this simple button to test the progress bar but nothing moves or shows. visible is true.... And I cannot see anything wrong...
See code below:

private void button1_Click(object sender, System.EventArgs e) {
pgProgress.TabIndex = 0;
pgProgress .Maximum =15;
pgProgress .Minimum =1;
pgProgress .Step =1;
for(int i=pgProgress.Minimum; i <= pgProgress.Maximum; i++) {
pgProgress.PerformStep();
this.Refresh();
}
}

Any help would be greatly appreciated.


Try

pgProgress.Refresh();

or

pgProgress.Update();

instead.

Nov 16 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: jez123456 | last post by:
Hi, thanks for the previous advice on progressbars with showing the percentage. I would now like to create a less clunky version. I.e at the moment my progressbar shows 7 separate steps. Some...
8
by: needin4mation | last post by:
Please consider: foreach (ListViewItem item in listViewFiles.Items) { // Display the ProgressBar control. pBar1.Visible = true; // Set Minimum to 1 to represent the first file being copied....
1
by: Mehr H | last post by:
I've been trying to figure out how i can embed a Windows.Forms.ProgressBar in my webform (aspx) file. I have tried putting a Windows.Forms.ProgressBar as public on a regular winform designer form...
2
by: Dinesh Jain | last post by:
Hi all , As we run the .NET exe, first of all it loads all the necessary system dlls and user dlls at load time and then displays the main form of the application. But in between loading these...
2
by: WannaBeProgrammer | last post by:
ok fellas, it's the wannaBe again with another lame queation. I have a little program thats due in at school today and I'm still on it after 2 wks!! it's really beating me up and I'm gettin to...
3
by: Mitchell Vincent | last post by:
In other programming languages I've been able to easily change the style of a progress bar between smooth and blocked. I find that is either really hidden or impossible in .NET. Am I missing...
1
by: nobody | last post by:
Hi I'm currently developing a Windows application. At the start of the application I load several tables into datatables in a dataset. I also use a progressbar to show the user how much percent...
2
by: =?Utf-8?B?QWFyb24=?= | last post by:
Since some controls such as the DataGridView take a long time to update themselves when performing certain tasks, I have added a StatusStrip with a ProgressBar on it. While I am updating the...
1
by: Jassim Rahma | last post by:
how can I copy a file to a folder with displaying a progressbar?
1
Kermit
by: Kermit | last post by:
Hi. I've searched the forum for answer, but haven't found one. The problem is with displaying the label. When the progressBar is incremented I change the text of the Label, but it doesn't...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.