Progress Bar

Submitted by: 

Progress Bar is used to give visualization about the status of the current process and computer operation, such as a downloading , transferring of files, installation and more. Your application will look more professional if you are implementing a complex data processing using the Progress Bar.
This time, we will create an example of a Progress Bar using Visual Basic. First, open visual basic and create a new project then, save it as “ProgressBar”. Then from the toolbox add a progressbar,label, button and a timer.
Next, we’re going to add functionality to our application. First, you need to set the progress bar's minimum value to 0 and the maximum value to 100. And double click the timer1, and add the following code:

  1. 'test if the value of progress bar is greater than or equal to 100
  2. If ProgressBar1.Value >= 100 Then
  3. 'set the value to minimum value which is equal to zero
  4. ProgressBar1.Value = 0
  5. Else
  6. 'increment the value of progress bar by 1
  7. ProgressBar1.Value = ProgressBar1.Value + 1
  8. 'display the current percent of the progress.
  9. Label1.Text = ProgressBar1.Value & "% Completing..."
  10. End If

To activate the timer, double click the button. And add the following code:

  1. Timer1.Start()

Then press “F5” to run your application.

Here’s the example output after completing the course.


Comments

merica is cool lol lol lol lol lol

hi ..i need help please response asap
were making a system which is the application forms , our problem, we cant create a progress bar ,its very important to our system . how can we get or how can we provide this one!!!

I followed instructions and get: compile error expected: = in Timer1.Start() highlighted in the command1.click event

It's cool.... Thanks man...however, I must click on the progress bar each time I want it to move forward.... Can that be corrected please? That is after pressing F5 to run.

good
i like it

Add new comment

Filtered HTML

  • Web page addresses and e-mail addresses turn into links automatically.
  • You may insert videos with [video:URL]
  • Allowed HTML tags: <a> <em> <strong> <cite> <blockquote> <code> <ul> <ol> <li> <dl> <dt> <dd> <table> <tr> <td> <th> <img> <h1> <h2> <h3> <iframe> [video]
  • You can enable syntax highlighting of source code with the following tags: <code>, <blockcode>, <asp>, <c>, <cpp>, <csharp>, <css>, <html4strict>, <java>, <javascript>, <mysql>, <php>, <python>, <sql>, <vb>, <vbnet>. The supported tag styles are: <foo>, [foo].
  • Lines and paragraphs break automatically.

Plain text

  • No HTML tags allowed.
  • Lines and paragraphs break automatically.
CAPTCHA
This question is for testing whether or not you are a human visitor and to prevent automated spam submissions.