[jboss-user] [JBoss Seam] - form controls with the same property name
schmod54
do-not-reply at jboss.com
Wed Sep 19 07:10:07 EDT 2007
How do I add error messages to a particular control if multiple controls share the same property name on the same page? E.g., say I have a user registration form, where usernames are unique. If a user enters a duplicate username, in my action bean I can add an error like so:
facesMessages.addToControlFromResourceBundle("username", "usernameExists");
But say I have a batch user registration process that allows someone to register 10 users at a time. If I use the same code, then the error message gets displayed at the top of the page and the user doesn't know which username is invalid. I could change the error message to contain the invalid name, but I would rather display it next to the relevant control. So how do I do that? Thanks!
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4085981#4085981
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4085981
More information about the jboss-user
mailing list