Copyright Codenstuff.com 2017
YOU NEED TO BE LOGGED IN TO USE THIS FEATURE


Register
Credits
0
Reputation
0
progress percentage between two amounts ?
If you need help with a project or need to know how to do something specific in VB.NET then please ask your questions in here.
Forum rules
Please LOCK your topics once you have found the solution to your question so we know you no longer require help with your query.


Hello,

Can someone help me with this piece :)

we have for example 2 amounts

first one will be 15.000.00
second one will be 750.00

how can we get the percentage to set with progressbar value? to fill up the bar
to see how far we get with the payment

when offcource payed everything we must get 100%
so the progressbar will be full :D

Thanks

Quickly coded, hope this helps:

Code: Select all
Dim SetAmount = "15.000.00"
        Dim CurrentAmount = "750.00"
        ProgressBar1.Value = (100 * CurrentAmount.Replace("."c, "")) / SetAmount.Replace("."c, "")

Welcome to CodenStuff.com Learn Code, Love Code. Thank you for being a member of the community.



Online now

Users viewing this forum: No registered users and 1 browsing

cron