# Question about inserting commas

**URL:** <https://forum.kirupa.com/t/question-about-inserting-commas/218572>\
**Category:** flash\
**Created:** [March 8, 2007, 10:12pm UTC](https://forum.kirupa.com/t/question-about-inserting-commas/218572 "2007-03-08T22:12:02Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![fnordboy](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/fnordboy/32/3425_2.png) [@fnordboy](https://forum.kirupa.com/u/fnordboy)\
**Post date:** [March 8, 2007, 10:12pm UTC](https://forum.kirupa.com/t/question-about-inserting-commas/218572/1 "2007-03-08T22:12:02Z")

</div>

Hello.

I have been working on a calculator for an annual incentive plan that displays several dollar amounts (old salary, new salary, bonus, etc.). I have found a few functions for doing the conversion but I can’t seem to figure out how to get this into the fla for it to work properly.

Basically I have some code pulling from input boxes:

```auto

//12 Month AIP calculations
var AIPmonthRaw = Math.round(Number(baseSalary.text) - newBase);
var AIPmonth = Math.round(AIPmonthRaw * Number (.01)) * 100;

```

At this point I want to convert the AIPmonth var to have a comma (ie 25,000) when it displays in the dynamic text box.

The same would go for about 4 other different amounts displaying in other dynamic boxes.

The two formatters I was looking at were found here:  
[http://www.actionscript.org/actionscripts\_library/Math\_Object/more5.shtml](http://www.actionscript.org/actionscripts_library/Math_Object/more5.shtml)

Thanks in advance.
