Code for adding negative numbers

Avatar

Avatar

carlos4457

Avatar

carlos4457

carlos4457

31-07-2017

How to add negative numbers such as tax credits and discounts in an expanding table. The "Total" field only adds the purchases which are debits but does not add the credits.

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar

Magus069

MVP

Total Posts

1.0K

Likes

132

Correct Answer

150

Avatar

Magus069

MVP

Total Posts

1.0K

Likes

132

Correct Answer

150
Magus069
MVP

01-08-2017

Hi there,

you can use the Math.abs(); which puts any number value to positive value and use the negative sign in front.. like the following :

Answers (1)

Answers (1)

Avatar

Avatar

carlos4457

Avatar

carlos4457

carlos4457

02-08-2017

Thanks, it worked like a charm!