wood burning stoves 2.0*
The moose likes JSF and the fly likes Render a panelconfirmation conditionally Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » JSF
Bookmark "Render a panelconfirmation conditionally" Watch "Render a panelconfirmation conditionally" New topic
Author

Render a panelconfirmation conditionally

Neha Mahajan
Greenhorn

Joined: Apr 22, 2008
Posts: 7
I want to show a confirmation dialog on click of by Create commandlink but only when a particular condition is satisfied based on value enetered by the user in a text field. So I evaluate this condition inside the validator of that field and set the panelconfirmation only if that condition is satisfied:

HtmlCommandLink cmd = (HtmlCommandLink) FacesContext.getCurrentInstance().getViewRoot().findComponent(
"CreateCostForm:id_submitButtonCreateComm");
cmd.setPanelConfirmation("confirmCreateUpdate");


However, there's a loophole. If I enter something in the text field and directly click on Create link without losing focus from the field, the panelconfirmation is not set and the confirmation dialog doesnot appear.
Any workaround anybody?

Neha Mahajan
Greenhorn

Joined: Apr 22, 2008
Posts: 7
Any ideas???
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Render a panelconfirmation conditionally
 
Similar Threads
showInputDialog( ) focus
set jasper textfield attribute at runtime
HtmlCommandLink in a custom component
onfocus() is working fine in IE but not in Firefox
setContentType() does nothing.