Jump to content

ProgressBar/Percent of 2 numbers...


Recommended Posts

ok, hope this is the right section.. but anyways..

I have a menu in which a user selects 2 numbers, a min and a max. but i want to put a progress bar or a percent indicator to show the progress.

so i came up with...

GuiCtrlSetData($progressbar,$istart / $istop * $i * 100)

$istart is the inputbox for the starting number

$istop is the inputbox for the stopping number

$i comes from "for $i = $istart to $istop"

this works perfectly IF the $istart number is "1" anything else and it screws up... so any ideas of how i could make it work if the user put some other number like "123" or whatever into the start number?

i've been rackin my brain on this for the past couple hours, guess my math skills have been slipping lol.

Link to comment
Share on other sites

GuiCtrlSetData($progressbar,$istart / $istop * $i * 100)

try this.

GuiCtrlSetData($progressbar,(($i-$istart)/ ($istop-$istart)) * 100)

Cheers

Kurt

__________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf *

Link to comment
Share on other sites

nice sig btw LOL.

Thanks...

Cheers

Kurt

__________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf *

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...