I have a zone, and many nested components in it. I pass objects to these components by Environmental Service.
The first time page render is ok. But when I click an Action link which will refresh the zone, I can't get Environmental Object. And I get an Error like this: org.apache.tapestry5.ioc.util.UnknownValueException No object of type org.test.MyData is available from the Environment. availableValues Environmentals: org.apache.tapestry5.RenderSupport org.apache.tapestry5.ValidationDecorator org.apache.tapestry5.internal.services.DocumentLinker org.apache.tapestry5.services.ClientBehaviorSupport org.apache.tapestry5.services.FormSupport org.apache.tapestry5.services.Heartbeat org.apache.tapestry5.services.javascript.JavaScriptSupport org.test.MyData It says No object of type MyData is available, but in availableValues, there is my MyData. strange. I use tapestry-rc-3 now. But it works when I use tapestry 2.6. On Nov 7, 2011, at 6:44 PM, Thiago H. de Paula Figueiredo wrote: > On Mon, 07 Nov 2011 07:40:21 -0200, Bo Gao <eli...@gmail.com> wrote: > >> I saw a line in tapestry documents >> (http://tapestry.formos.com/nightly/tapestry5/guide/ajax.html) >> Inside a component, you should use Environmental, to highlight the fact that >> RenderSupport (like most environmental objects) is only available during >> rendering, not during action requests. > > Each Environmental object put or removed by different classes in Tapestry, so > there isn't a single answer for them. > >> In fact, I just want to use Environmental Service during a action requests. >> (i.e. a zone update) > > What service do you need and what methods? What you're trying to do? > > -- > Thiago H. de Paula Figueiredo > Independent Java, Apache Tapestry 5 and Hibernate consultant, developer, and > instructor > Owner, Ars Machina Tecnologia da Informação Ltda. > http://www.arsmachina.com.br -- Bo Gao eli...@gmail.com