Re: [FMPP] (Newbie) Dot in property causing exception
Brought to you by:
ddekany
|
From: Daniel D. <dd...@fr...> - 2006-02-06 22:35:22
|
Monday, February 6, 2006, 10:18:59 PM, Bruce Perryman wrote:
> Hi,
>
> I'm a newbie, and I wondered if there was a way around this.
>
> An element in a list has a '.' in the name. When I try to evaluate
> the _expression in FreeMarker an exception is thrown.
>
> The List contains the value I.lastname. When I try to access it from wi=
thin the
> =A0<#list name as x> as
>
> "${x.I.lastname}"
>
> FreeMarker tells me that x.I is undefined. Other than changing the
> element name, is there a way to do this?
??? Huh? I see you are newbie, as you use some kind of terminology that
I don't understand. :) List items doesn't have a name. They have an
integer index. Anyway, if what you really want is the read a subvariable
whose name contains dot (or whatever special character), then here is
how to do it:
foo["x.y.z"]
This will get the subvariable of "foo", which is called x.y.z.
--=20
Best regards,
Daniel Dekany
|