You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by "J. L." <dj...@yahoo.fr> on 2004/04/26 18:57:42 UTC

bean:write & formatKey

Hi,

I apologize if you have already answer to the problem
I just met but I was not able to find a solution in
the list archive.

Actually, I would like to use the bean:write tag in
order to format a number (the attribute 'nombre' is an
int).

My first JSP was :
<bean:write name="Test04_01_Form" format="#,##0.00"
property="nombre" />

And it worked well.

But when I try to use the formatKey attribute it does
not work anymore.

My second JSP :
<bean:write name="Test04_01_Form"
formatKey="ressources01.formatMontant"
property="nombre" bundle="res01" />

My ".properties" : 
ressources01.formatMontant=#,##0.00

And whent I try to access this page through my browser
I get the following error : 
org.apache.jasper.JasperException: Wrong format
string: '#,##0.00'

The most suprising is that formatKey works well when I
try to format a date !!!

If you have any ideas ?

Thanks in advance for your help.

J.L.


	

	
		
Yahoo! Mail : votre e-mail personnel et gratuit qui vous suit partout ! 
Créez votre Yahoo! Mail sur http://fr.benefits.yahoo.com/

Dialoguez en direct avec vos amis grâce à Yahoo! Messenger !Téléchargez Yahoo! Messenger sur http://fr.messenger.yahoo.com

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org