1

I have a question about the use of accountingMoney.FormatMoney in Accounting.js. If I am passing a negative value into a field in this format:

$('#newModFund4587').val(accounting.formatMoney(fund4587));

NewModFund4587 is a text box that can be modifiable. The value in fund4587 is negative. When I display the field it is showing the value as negative. But when I try to modify the text box or even just tab out of the field it changes to a positive value. When you use FormatMoney, is a negative value still stored as a negative or is converted to positive and formatted to show as negative.

Edit: I did find something that maybe explains this situation. When I take a new field and put in a negative amount, the value would show as '-100.00'. Then I changed the value to use the FormatMoney the value would convert to '$-100.00'. When I go back to that field and try to change it or even tab around it that is where it changes always to a positive value.

If you have a field that begins with a '$' does it assume that it will always be positive? If a field began with '-$' would it treat it as negative?

Thanks

hammerva
  • 129
  • 1
  • 14

0 Answers0