Announcement

Collapse
No announcement yet.

Progress bar implanted

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Progress bar implanted

    I made a test of progress bar with a lot of code... It's the better way I found for a progress bar. There is no song in the test. You must add code mp3.play("") in the play button and copy the song to distribution folder.

    I have upload the test to an email account cause the attachements are turn off for this forum.

    at www.mail.yahoo.com
    Username : testprogress
    password : access

    plz, give me all of your suggestions.. thx

  • #2
    Re: Progress bar implanted

    Not bad. [img]/ubbthreads/images/icons/smile.gif[/img]

    A few quick thoughts:

    - in your calculations to get %PrTi% and %PrTT%, you should do Variable.FormatNumber (to round the values) after performing the division. Whenever you round a number in a calculation, you want to do it as late as possible. In this case, you're actually displaying values every now and then that aren't rounded to 2 digits, because the rounding is performed too early.

    - you could replace most of the show/hide code for the progress display with a simple loop. Something like this:<font color=green><pre>%i% = "1"
    %ledindex% = Evaluate (50 * %PrTT%)
    %ledindex% = Variable.FormatNumber (%ledindex%, 0, Round)
    WHILE (%i% <= 50)
    IF (%ledindex% = %i%)
    Page.ShowObject ("LedA%i%")
    ELSE
    Page.HideObject ("LedA%i%")
    END IF
    %i% = Evaluate (%i% + 1)
    END WHILE
    </pre>
    </font color=green>

    (This won't work 100% when you seek manually, though, because of rounding errors in your other calculations...but it should give you the general idea.)
    --[[ Indigo Rose Software Developer ]]

    Comment


    • #3
      Re: Progress bar implanted

      Thanks Lorne for your codes and the time you had pass to check my test. It will help me to reduce extremely the code.

      I have a question about Flash. How can i do for interac flash code with AMS. Is it possible ? Exemple : I want to program a flash progress bar that will receive in parameter the lenght and the progress time of the song that play in my AMS application. Does I can send parameter from Flash objet or fonction to my AMS appl ? Because if I can, the flash objet will adjust perfecly its progress bar in function of parameters (the speed of the progress, etc).

      Comment


      • #4
        Re: Progress bar implanted

        Sure that's easy. I created one that works but I lost it. Just create a flash movie 100 frames in length which contains a tween of a solid rectangle. Make sure in each keyframe (1 and 100) the bar symbol is left aligned.

        Then just use the FLASH OBJECT > SEEK action within your code to place the bar at the correct percentage in length by seeking to the corresponding frame, i.e. 1-100. I hope I explained this well enough, it's really super easy, takes less than 3 minutes to do the flash...

        Corey Milner
        Creative Director, Indigo Rose Software

        Comment


        • #5
          Re: Progress bar implanted

          Any chance of you creating this for those of us who are flash-impaired? Certainly would be appreciated!

          Comment

          Working...
          X