Javascript Text Alignment in TextBox
634176Sep 24 2008 — edited Sep 25 2008I have a textbox item, P1_MY_AMT, which contains amount value in "$9,999,999.55" format. I have a function that takes user input (numbers) and formats it with a dollar sign, and commas and returns the formatted value to the textbox. I'm using the onBlur event to display the value to the user.
What I need to do is align the "$" to the left side of the textbox (left justified), and the amount to the right of the textbox (right justified). I have to do this strictly using javascript, and cannot use any built-in stuff from Apex, since this function will ultimately be also used in another html based app.
Any ideas on how I can achieve this?
Any help is appreciated.