• Post Reply Bookmark Topic Watch Topic
  • New Topic

clear h:messages?  RSS feed

 
nimo frey
Ranch Hand
Posts: 580
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Does anyone know how I can clear the list of facesMessages in a managedBean?
 
Anil kumar
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
try ..

Iterator messageIterator = FacesContext.getCurrentInstance().getMessages();
while (messageIterator.hasNext()) {
messageIterator.remove();
}
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!