Cool, cheers Taha, This took me a while to understand so I'll re-iterate for my sake!
You're saying for EventLinks we need to drop the "From" clause because the event isn't acutally raised in the eventLink but the container, so the following should work: @OnEvent(value="postConversationEvent") void valueChosen() { System.out.println("annotated version"); } void onPostConversationEvent() { System.out.println("convention version"); } Steve. On 10 November 2011 12:27, Taha Hafeez Siddiqi <tawus.tapes...@gmail.com> wrote: > Hi > > EventLinks have event handlers of the form > > on'EventName' > > and the event name defaults to the component id. > > 'FromComponent' is not going to work as the event is triggered in the > container without reference to the component triggering it. This allows > shorter url > > http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/corelib/components/EventLink.html > > regards > Taha > > On Nov 10, 2011, at 3:43 AM, bogdan_cm wrote: > >> I am stuck on a rather silly operation. I have an eventLink in the tml and >> it's event handler in the class like so: >> >> tml -> < a t:id='postConversationLink'>click the link < / a > >> >> class -> >> >> @Component(parameters = {"event=postConversationEvent"}) >> private EventLink postConversationLink; >> >> @OnEvent(value="postConversationEvent", >> component="postConversationLink") >> void valueChosen() >> { >> System.out.println("annotated version"); >> } >> >> void onPostConversationEventFromPostConversationLink() >> { >> System.out.println("convention version"); >> } >> >> >> To me both the annotated version and the convetion version look correct. >> However, for both i get the error: Request event 'postconversationevent' ... >> was not handled. >> From the message it looks like the link is actually generating the event, >> but somehow it cannot be matched to any of the two handlers. >> >> Thank you, >> Bogdan. >> >> -- >> View this message in context: >> http://tapestry.1045711.n5.nabble.com/EventLinks-and-their-handlers-tp4979300p4979300.html >> Sent from the Tapestry - User mailing list archive at Nabble.com. >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org >> For additional commands, e-mail: users-h...@tapestry.apache.org >> > > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org