Results 1 to 10 of 10

Thread: start up program with Progressbar

  1. #1

    Thread Starter
    Frenzied Member
    Join Date
    Feb 2007
    Location
    Malaysia
    Posts
    1,370

    start up program with Progressbar

    I would like to know how to use progressbar base on the time it taken to start up the program
    I use progressbar and timer but I not involved the time taken to to start up the program

    Private Sub Timer1_Timer()
    ProgressBar1.Value = ProgressBar1.Value + 5
    If ProgressBar1.Value = 100 Then
    Timer1.Enabled = False
    Unload Me
    frmDateChecker.Show
    frmMenu.Command9.Enabled = False
    frmMenu.Command9.Visible = False
    End If


    End Sub
    Last edited by matrik02; Nov 24th, 2007 at 07:24 AM.

  2. #2
    PowerPoster Fazi's Avatar
    Join Date
    Aug 2005
    Location
    Underworld
    Posts
    2,525

    Re: load system using Progressbar

    Matrik,
    system mean the time it took to boot the system or your program ?

  3. #3

    Thread Starter
    Frenzied Member
    Join Date
    Feb 2007
    Location
    Malaysia
    Posts
    1,370

    Re: start up program with Progressbar

    Time it taken to start up the program. What i mean is the status with progress bar. I use Microsoft access database.

  4. #4
    Frenzied Member aikidokid's Avatar
    Join Date
    Aug 2002
    Location
    Bristol, UK
    Posts
    1,968

    Re: start up program with Progressbar

    matrik02, I've not used a progress bar, but there are plenty of threads about it here in the forums.

    Take a look here.

    I would guess you would get the number of records from the database and then divide that number by 100 and then increment your prograss bar by one each time.

    E.G.
    1000 records
    Every 10 records loaded add 1 to you progressbar - assuming you have the total set to 100
    Last edited by aikidokid; Nov 24th, 2007 at 07:50 AM. Reason: added link
    If somebody helps you, take time to RATE the post. I do.

    "FAILURE IS NOT AN OPTION. It comes bundled with the software."

    Below are some of the threads that have helped me along the way:

    CodeBank submission:
    Listview Backcolor (without subclassing)

    Loading Treeview Nodes From A Database, Creating Registry Keys, Count Number of Lines in TextBox , Excellent RichTextBox Tricks & Tips
    Ideas & Screen Shots For A Code Library App
    How to do Data validation in Excel, Conditional Formating in Excel

  5. #5
    Super Moderator si_the_geek's Avatar
    Join Date
    Jul 2002
    Location
    Bristol, UK
    Posts
    41,974

    Re: start up program with Progressbar

    To use a progressbar, you need something you can measure - like the number of records (amount processed so far versus the total amount) as aikidokid explained.

    For more information (and alternatives for when you don't have something to accurately measure), see the article How can I use a progress bar? from our Classic VB FAQs (in the FAQ forum, which is shown near the top of our home page)

  6. #6

    Thread Starter
    Frenzied Member
    Join Date
    Feb 2007
    Location
    Malaysia
    Posts
    1,370

    Re: start up program with Progressbar

    It is possible to used progress bar to measure the number of total records in the database plus the time taken by computer to process the program?

  7. #7
    Frenzied Member aikidokid's Avatar
    Join Date
    Aug 2002
    Location
    Bristol, UK
    Posts
    1,968

    Re: start up program with Progressbar

    Quote Originally Posted by matrik02
    It is possible to used progress bar to measure the number of total records in the database plus the time taken by computer to process the program?
    matrik02, yes it is in the way I described in my first post #2
    If somebody helps you, take time to RATE the post. I do.

    "FAILURE IS NOT AN OPTION. It comes bundled with the software."

    Below are some of the threads that have helped me along the way:

    CodeBank submission:
    Listview Backcolor (without subclassing)

    Loading Treeview Nodes From A Database, Creating Registry Keys, Count Number of Lines in TextBox , Excellent RichTextBox Tricks & Tips
    Ideas & Screen Shots For A Code Library App
    How to do Data validation in Excel, Conditional Formating in Excel

  8. #8
    PowerPoster
    Join Date
    Nov 2002
    Location
    Manila
    Posts
    7,629

    Re: start up program with Progressbar

    Quote Originally Posted by matrik02
    It is possible to used progress bar to measure the number of total records in the database plus the time taken by computer to process the program?
    Will process actually take up a significant amount of time to warrant creation of a progress bar? Your not building the progress bar just for aesthetic reasons? If it's really not necessary then your time is better spent improving other areas of your program.

  9. #9

    Thread Starter
    Frenzied Member
    Join Date
    Feb 2007
    Location
    Malaysia
    Posts
    1,370

    Re: start up program with Progressbar

    Quote Originally Posted by aikidokid
    matrik02, I've not used a progress bar, but there are plenty of threads about it here in the forums.

    Take a look here.

    I would guess you would get the number of records from the database and then divide that number by 100 and then increment your prograss bar by one each time.

    E.G.
    1000 records
    Every 10 records loaded add 1 to you progressbar - assuming you have the total set to 100
    I can't imagine without a sample code. I have many tables let say 10 tables.. How to get the total of records for each tables ?

  10. #10
    Frenzied Member aikidokid's Avatar
    Join Date
    Aug 2002
    Location
    Bristol, UK
    Posts
    1,968

    Re: start up program with Progressbar

    Like I saia matrik02, I haven't used one, but here is a sample code
    If somebody helps you, take time to RATE the post. I do.

    "FAILURE IS NOT AN OPTION. It comes bundled with the software."

    Below are some of the threads that have helped me along the way:

    CodeBank submission:
    Listview Backcolor (without subclassing)

    Loading Treeview Nodes From A Database, Creating Registry Keys, Count Number of Lines in TextBox , Excellent RichTextBox Tricks & Tips
    Ideas & Screen Shots For A Code Library App
    How to do Data validation in Excel, Conditional Formating in Excel

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width