![]() |
|
[.NET] [Beginners] ProgressBar [/TuT] - Printable Version +- Hack Forums (https://hackforums.net) +-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444) +--- Forum: Coding (https://hackforums.net/forumdisplay.php?fid=151) +---- Forum: Software Development (https://hackforums.net/forumdisplay.php?fid=118) +---- Thread: [.NET] [Beginners] ProgressBar [/TuT] (/showthread.php?tid=478565) |
[Beginners] ProgressBar [/TuT] - The-One - Jun 13, 2010 Hello people! Today i'm going to teach you beginners in vb.net how to make a progress bar. Needs: - Visual basic 2008/2010 - New Project - 1 Form What are we going to do? I'm going to make the progressbar show values and when it reach's a value it pops a message box with the time (in seconds) how long it took to reach the value. Okey, this is my GUI: [img]http://i48.[censored].com/126bnd3.png[/img] (ALSO ADD A TIMER! ) Coding: Double click the button1(Text=Start): Code If Timer1.Enabled = False Then ' If the timer isn't running do:Next, Form1.Load: Code ' This is what we are going to use as a count systemAfter that, double click the timer (Timers interval= 500): Code Dim Nmr As Integer = 0 ' Define a integerAnd if u did it all right, you got 1 error at the GRN(GenerateRandomNumber)(Add this somewhere in your form class): Code Public Function GRN(ByVal min As String, ByVal max As String)Full Source: Spoiler (Click to View) Enjoy! Rate,Comment etc. etc! * - Beck - Jun 13, 2010 Nice source, mate :) 😉 I will check it out later if I ever get the time to. * - Mr. Mischief - Jun 13, 2010 i already know this... but will save it as a snippet just incase i forget. thanks :D * - The-One - Jun 13, 2010 (Jun 13, 2010 09:33 AM)Beck Wrote: Nice source, mate :) Thanks, good luck. (Jun 13, 2010 09:36 AM)bluestu10 Wrote: i already know this... Okey. No problem |