Congratulations to all the winners of April 2013, they have won INR 3400 cash and INR 20147 worth prizes !
DotNetFunda.Com Logo
Twitter TwitterLinkedIn
YouTubeGoogle
 Online : 42842 |  Welcome, Guest!   Register  Login
 Home > Forums > VB.NET > handling progress bar in vb.net ...
Thiru

handling progress bar in vb.net

Replies: 4 | Posted by: Thiru on 4/18/2012 | Category: VB.NET Forums | Views: 3280 | Status: [Member] | Points: 10  


Hi Friends,
I have a status bar with progress bar in MDI Form
i like to activate progress bar when some process is going on in child form.

How to call / activate the progress bar in parent form From Child Form ?

regards,
Thiru.


Reply | Reply with attachment | Alert Moderator

 Responses below this adGet hundreds of .NET Tips and Tricks videos

 Replies

Sakthi.Singaravel
Sakthi.Singaravel  
Posted on: 4/18/2012 11:27:53 AM
Level: Silver | Status: [Member] | Points: 25

Simple progress bar using method...

For Each filename In files 'files contains list of files

file_count += 1
ToolStripProgressBar1.Value += 1
ToolStripStatusLabel2.Text = file_count & "/" & files.Count
Next


Regards,
Singaravel M

Thiru, if this helps please login to Mark As Answer. | Reply | Alert Moderator 

Thiru
Thiru  
Posted on: 4/18/2012 11:32:05 AM
Level: Starter | Status: [Member] | Points: 25

Thanks for your reply Singaravel,
i am lacking to handle/call ProgressBar in MDI form
From Child form.

Thiru, if this helps please login to Mark As Answer. | Reply | Alert Moderator 

Sunny4989
Sunny4989  
Posted on: 4/19/2012 5:55:38 AM
Level: Starter | Status: [Member] | Points: 25

Step 1:

Open a Visual Basic project.
Double-click the "Progress Bar" control on the toolbar to add "ProgressBar1" to the form.
Double-click the "Button" control to add "Button1" to the form.

Step 2

Press "F7" to open the code window. Open the "Form1_Load" subroutine and type the following:
ProgressBar1.Minimum = 0
ProgressBar1.Maximum = 5
ProgressBar1.Value = 0

This code sets the starting values for the progress variable, as well as the minimum, maximum and current values for the progress bar. You can set a different maximum value depending on what you need the progress bar for.

Step 3:
Open the "Button1_Click" subroutine and type the following:

If ProgressBar1.Value < ProgressBar1.Maximum Then
ProgressBar1.Value += 1
If ProgressBar1.Value = ProgressBar1.Maximum Then
MsgBox("Finished!")
End If
End If


------------------------------------------------
Learn throughout life

Thiru, if this helps please login to Mark As Answer. | Reply | Alert Moderator 

Thiru
Thiru  
Posted on: 4/19/2012 5:06:18 PM
Level: Starter | Status: [Member] | Points: 25

Thanks for your reply,
Nice example code.
But i need to have the status bar with progress bar in mdi form
and control the same from child form

i dont know how to change the current form name in mdi statusbar.label and progress bar

help me in this regard please.

Thiru, if this helps please login to Mark As Answer. | Reply | Alert Moderator 

Reply - Please login to reply


Click here to login & reply

About Us | Contact Us | The Team | Advertise | Software Development | Write for us | Testimonials | Privacy Policy | Terms of Use | Link Exchange | Members | Go Top
General Notice: If you find plagiarised (copied) contents on this page, please let us know the original source along with your correct email id (to communicate) for further action.
Copyright © DotNetFunda.Com. All Rights Reserved. Copying or mimicking the site design and layout is prohibited. Logos, company names used here if any are only for reference purposes and they may be respective owner's right or trademarks. | 5/20/2013 8:08:25 AM