I don't think that anybody has tried this yet. The AjaxEventSubmit component is intented (for now) to submit the whole form and call a listener. Hence the "Submit" suffix. This is important in many cases where people need to change the old "combo-box changed -> refresh" pattern that plage a lot of web apps. So it works mostly like a submit button.

(I'm not sure if in a regular Submit button the form's listener is called too. If that's not the case then AjaxEventSubmit shouldn't do it. But I think is the case indeed).

You might want to take a look to how Autocomplete is working. Maybe it would shed some light on your purposes.

--
Ing. Leonardo Quijano Vincenzi
DTQ Software


Jeremy wrote:

Hi guys. Looks like this is going in a cool direction. However, I’m a little confused about the version in alpha-7.

I’m building a form with a TextArea that kindof works like an AutoCompleter. I put the TextArea inside an AjaxForm, and I’ve attached an AjaxEventSubmit to the onkeyup event of the TextArea.

The server-side listener needs the input of the TextArea to generate suggestions. (BTW: I can’t use an AutoCompleter because the suggestions shouldn’t appear in a pull down, they need to appear in some other part of the page.)

So the AjaxEventSubmit gives me two choices for attaching a listener. I can use the “action” parameter which causes tacos to fire the specified listener right before firing the form’s listener. Or I can use the “listener” parameter which causes tacos to fire the listener method when the AjaxEventSubmit component rewinds.

In the first case, my form’s listener fires too. That’s not the behavior I want. I only want the AjaxEventSubmit listener to fire in this case.

In the second case, the listener **must** fire before the TextArea rewinds because I **must** place the AjaxEventSubmit component before the form elements which trigger it. So in this case, my listener can’t get the data it needs.

I don’t quite know what to do here. Am I using the AjaxEventSubmit component for an unintended purpose? I notice that the AjaxForm in the demo doesn’t have a “listener” parameter or a LinkSubmit or anything. Perhaps nobody has tried this yet?

Thanks for your help!

Jeremy






-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
_______________________________________________
Tacos-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tacos-devel

Reply via email to