[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

Validate modification in ajax on a h:selectOneListbox

Posted on 2009-06-29
5
Medium Priority
?
370 Views
Last Modified: 2013-11-24
Hi!

I need to do the same thing that the related question, this time this is on a html event, so I don't know exactly how to manage this with the a4j:support?

OR

Is there an other component in richfaces that have the same display and have listener? or permit to have an direct synchronisation with the bean?
0
Comment
Question by:Nargzul
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 60

Expert Comment

by:Kevin Cross
ID: 24740370
Check the ajaxValidator, should work.  This page gives example of how to code the ValidationBean and include the tag in JSF.

http://livedemo.exadel.com/richfaces-demo/richfaces/ajaxValidator.jsf?c=ajaxValidator&tab=usage
0
 
LVL 1

Author Comment

by:Nargzul
ID: 24740453
But I've nothing to validate on this field.

In facts, at the final validation, he could be empty, it's just an intermediary container
0
 
LVL 60

Expert Comment

by:Kevin Cross
ID: 24740543
Oh, sorry guess I misunderstood.  Thought you were looking to do validation.

I am not sure, so will have to do some research.  I know there is a4j:ajaxListener, but I have not used enough to know for certain that is what you need; however, you can give it a try.  It is guaranteed to be invoked for every AJAX response before the Render Response fires.
0
 
LVL 1

Author Comment

by:Nargzul
ID: 24745516
I've try this but it doesn't work.

I've found this:
http://www.jroller.com/a4j/entry/ajax_updates_inside_jsf_complex1
But I've an error because the "selectOneListbox"  "Parent component treetake for a ajaxListener is not source of AjaxEvents"


<a4j:outputPanel id="ajxpn1" ajaxRendered="true">     
   <h:selectOneListbox id="listservtake"  rendered="#{AddDeal.serv!=null}" value="#{AddDeal.currentService}" >
      <f:selectItems  value="#{AddDeal.serv}"/>
   </h:selectOneListbox>
</a4j:outputPanel>

Open in new window

0
 
LVL 1

Accepted Solution

by:
Nargzul earned 0 total points
ID: 24745553
Sorry, I put the wrong error: "Parent component listservtake for a ajaxListener is not source of AjaxEvents"
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction This article is the last of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers our test design approach and then goes through a simple test case example, how …
A solution for Fortify Path Manipulation.
The viewer will learn how to implement Singleton Design Pattern in Java.
This tutorial covers a practical example of lazy loading technique and early loading technique in a Singleton Design Pattern.
Suggested Courses

656 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question