Jump to content

Return Money


Recommended Posts

hi people, i need help in a dumb function >.<

for example:

i have the value U$ 999,00

i need to divide the value by 6, 5, 4, 3 and 2

the value has to return with a comma, not point

and also with two decimal places after the comma

I tried to use the Round, but it did not work ...

code example:

$value = Number("999,00")
$divides = 6
Dim $msg
$msg = ""

For $i = $divides To 1 Step -1
    $msg = $msg & @CRLF & $i & "x " & $value / $i & @CRLF
Next

MsgBox(0, "Values", $msg)

he would have to return:

6x 166,50

5x 199,80

4x 249,75

3x 333,00

2x 499,50

1x 999,00

if someone can help me ...

thanks =)

Edited by golfinhu
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...