velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Shinobu Kawai <>
Subject Re: Problems with ViewRenderTool
Date Sat, 11 Dec 2004 01:10:43 GMT
Hi Binu,

> I have problem with the Velocity ViewRender tool. Please see the macro
> below...
> The problem lies with the statement $render.eval("$e.$text")
> Here $e is an object and $text contains a string value that is a property of
> the object.

Let's say that "foo" was the value of $text.  What you really want to
do is $render.eval("$").  You can either make such a variable and
pass it to $render.eval(), or you can use $render.recurse() to get the

The first one works something like this:
#set($D = "$")
#set($getText = "${D}e.$text")

and the second like this:
#set($D = "$")

Of course, if the result contains VTL-ish stuff, you'll have to use
the first one because recurse() will keep on evaluating it.

Best regards,
-- Shinobu Kawai

Shinobu Kawai <>

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message