This week's giveaway is in the Spring forum.
We're giving away four copies of Microservices Testing (Live Project) and have Chris Love & Andres Sacco on-line!
See this thread for details.
Win a copy of Microservices Testing (Live Project) this week in the Spring forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
  • Campbell Ritchie
  • Tim Cooke
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
  • Liutauras Vilda
  • Henry Wong
  • Devaka Cooray
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Al Hobbs
  • Carey Brown
  • Piet Souris
  • Mikalai Zaikin
  • Himai Minh

H:commandButton onClick issue

Ranch Hand
Posts: 43
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

In my page i have one rich:dataTable (say DT1) which includes multiple records and one colum have command button (Say BTN1), on click of BTN1 one modal panel opens. Modal panel (Say MP1) include one textarea and one commandbutton (say BTN2), textarea in this modal panel can't be blank so i provided the required=true validations. on BTN2 click the DT1 must be reRendered and the MP1 must be hide. so i provided the oncomplete code of BTN2 in the action method of bean class so that the modal panel will only hide when the action method call.

NOTE: in case of validation failure on textArea, the action method will not execute

The whole scenario is working fine for the first case but when the DT1 rerendered properly and if i again hit on BTN1, the MP1 will appear but if the textArea is blank then the modal panel hide. (I don't want this scenario)....

Please help
Too many men are afraid of being fools - Henry Ford. Foolish tiny ad:
Free, earth friendly heat - from the CodeRanch trailboss
    Bookmark Topic Watch Topic
  • New Topic