Hi Marcelo,

thats true, it's presentation. Haven't you got FormBeans to get the data for presentation layer (in fact, they are belonging to the presentation layer, too). I would put this in the getter of my FormBeans, which should not be the BusinessObjects anyway?

Regards

Marcelo Epstein wrote:
Its not working..
I donīt want to insert the code inside the getter method, because it is
presentation not business.

<bean:write name="unidade" property="foneCom1" format ="(###)###'-'####"/>

foneCom1 is a String.

Any guess??



----- Original Message ----- From: "Nathan Maves" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" <[EMAIL PROTECTED]>
Sent: Tuesday, August 03, 2004 5:58 PM
Subject: Re: Format Phone numbers using bean:write




Did you try to put the () in '' as in

<bean:write name="unidade" property="foneCom1" format
="'('###')'###'-'####"/>

just a guess.. :)

On Aug 3, 2004, at 2:03 PM, Marcelo Epstein wrote:


Hi,

This is not working.

<bean:write name="unidade" property="foneCom1" format
="(###)###'-'####"/>

foneCom1 is a String.

Marcelo



----- Original Message -----
From: "Jim Barrows" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" <[EMAIL PROTECTED]>
Sent: Tuesday, August 03, 2004 4:10 PM
Subject: RE: Format Phone numbers using bean:write





-----Original Message-----
From: Marcelo Epstein [mailto:[EMAIL PROTECTED]
Sent: Tuesday, August 03, 2004 11:35 AM
To: Struts Users Mailing List
Subject: Format Phone numbers using bean:write


Hi all,

Is it possible to format a phone number stored in a String using
<bean:write> tag ?

I can format dates, but not Strings.

(###)###'-'#### for a us number might just do it......


Thanks in advance,
Marcelo


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]




--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to