Try putting single quotes around the hyphen. The formatter might be interpreting it as a minus or negative sign.
-----Original Message----- From: Bharathi Balasubramanian [mailto:[EMAIL PROTECTED] Sent: Wednesday, May 12, 2004 10:21 AM To: '[EMAIL PROTECTED]' Subject: fmt:formatNumber tag Hello there, I'm trying to use the fmt:formatNumber tag to format a phone number ... does anyone know how to do this? http://www.awprofessional.com/articles/article.asp?p=102219 <http://www.awprofessional.com/articles/article.asp?p=102219&seqNum=5> &seqNum=5 <fmt:formatNumber value="${calc.value1 + calc.value2}" pattern="###,###"/> The pattern indicates that there should be a comma after every three digits. It would also be legal to provide a decimal point, as in ###,###.##, which would indicate that a comma should be placed every three digits, with two digits following the decimal point. The example on this page suggests that this should work: <fmt:formatNumber pattern="###-####" value="${phone.phoneNumber}"/> But unfortunately that prints out: 2228014- Any ideas? --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]