Click here to Skip to main content
15,890,282 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi Friends, i have a many forms in windows application. each and every having a progress bar. I want to apply the progress bars to all forms.Here problem is I do not know Maximum records in my forms. how can do that process in forms. But here some internal process is going long time.

Please any one help me.
Posted
Updated 22-Aug-13 1:29am
v2

Please, read this article: ProgressBars[^]. There you'll find information how to use progressbars.
 
Share this answer
 
Public Class Form1

Dim iCounter As Integer

Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick

If iCounter > ProgressBar1.Maximum Then
Exit Sub
End If

ProgressBar1.Value = iCounter
iCounter = iCounter + 1
End Sub

Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Timer1.Enabled = True
End Sub

Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
Timer1.Enabled = False
End Sub

Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
iCounter = 0
ProgressBar1.Value = 0
End Sub
End Class
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900