2 Replies Latest reply on Oct 30, 2009 5:07 AM by pauland

    progress bar

    KalavatiSingh Level 1

      Hi,

            I want to code a progress bar that should  show progress when I click on a start button & conversly should stop when i click on stop button . After the scanning is complete I want a message to poped out saying "Complete". I have seen many examples that  show the progressbar , but could not find with start & stop button .any example ,idea or document please forward.

       

       

       

       

      Regards

      Kalavati Singh

      kalavati_singh@yahoo.co.in

        • 1. Re: progress bar
          pauland Level 4

          Usually progress bars are driven from events coming from a loader loading an assets of some kind, and it would normally make no sense at all to stop the progress bar from updating.

           

          You mention scanning. What exactly are you doing?

           

          At a guess, I would say that you are going through some kind of workflow and using a progress bar to indicate where the user is in the workflow. If this is the case, you don't need a start and stop button you just need to get the user to press a "next" button or something when each stage is complete and then update the progress bar then.

           

           

          Paul

          • 2. Re: progress bar
            Subeesh Arakkan Level 4

            Hello,

             

            Progressbar has a manual mode.

             

            In manual mode, mode="manual", you use an indeterminate ProgressBar control with the maximum and minimum properties and the setProgress() method. The setProgress() method has the following method signature:

            setProgress(Number completed, Number total)

            So when the start button is pressed, start the scanning . Update the progressbar using the setProgress() method as the scanning progresses.

             

            Progressbar dispatches a complete event when the load is completed. Listen for this event and show the alert or custom message.

             

            Check these doc pages

             

            http://livedocs.adobe.com/flex/3/html/help.html?content=controls_20.html

            http://livedocs.adobe.com/flex/3/langref/mx/controls/ProgressBar.html