I did indeed put quiet notation, just forgot to add it here. - Manish
----- Original Message ----- From: "Nathan Bubna" <[EMAIL PROTECTED]> To: "Velocity Users List" <velocity-user@jakarta.apache.org> Sent: Monday, January 31, 2005 9:21 PM Subject: Re: Adding map to toolbox > or you can just use quiet notation: > > $!mymap.put('label.name', 'manish') > > > On Mon, 31 Jan 2005 19:58:31 +0530, Manish <[EMAIL PROTECTED]> wrote: > > Never mind, I got it. > > It was printing it because return value for all these map.put operations was > > NULL. > > call to clear() wasn't printed because it is void. > > I put this all like this, and it's working now - > > > > <!-- > > $mymap.clear() > > $mymap.put("label.name","manish") > > $mymap.put("label.country", "India") > > --> > > > > - Manish > > > > ----- Original Message ----- > > From: "Manish" <[EMAIL PROTECTED]> > > To: "Velocity Users List" <velocity-user@jakarta.apache.org> > > Sent: Monday, January 31, 2005 7:32 PM > > Subject: Adding map to toolbox > > > > > Well, I tried to ad a HashMap to a toolbox as well, but none of its > > methods > > > (put basically) is working except clear() > > > > > > This is what I did in tool box- > > > > > > <tool> > > > <key>mymap</key> > > > <scope>application</scope> > > > <class>java.util.HashMap</class> > > > </tool> > > > > > > Then I my velocity code I try this - > > > > > > $mymap.clear() > > > $mymap.put("label.name","manish") > > > $mymap.put("label.country", "India") > > > > > > but It doesn't work. The template shows me this - > > > > > > $mymap.put("label.name","manish") $circus.map.put("label.country", > > "India") > > > > > > The clear is not shown, so I am assuming that it's getting executed a > > $mymap > > > is not NULL. > > > Any help, pointers??? > > > > > > TIA, > > > - Manish > > > > > > > > > > > > --------------------------------------------------------------------- > > > 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]