| Author |
Validation For Tomahawk inputCalender Component
|
koney sandeep
Greenhorn
Joined: Jul 02, 2008
Posts: 2
|
|
Hi Everyone, I have used tomahawk inputCalender Component in my jsp. I want to validate that date i.e., that date should be less than system date. How can i do that?? i have implemented Custom one but its not working with that tomahawk component. Please help me in this issue. Thanks in advance  [ July 02, 2008: Message edited by: koney sandeep ]
|
 |
Venkat Sadasivam
Ranch Hand
Joined: May 10, 2008
Posts: 139
|
|
You can use validator attribute of <t:inputCalendar> validator A method binding EL expression, accepting FacesContext, UIComponent, and Object parameters, and returning void, that validates the component's local value.
|
“Any fool can write code that a computer can understand. Good programmers write code that humans can understand. ”<br>
-Martin Fowler
|
 |
koney sandeep
Greenhorn
Joined: Jul 02, 2008
Posts: 2
|
|
can you send me the code snippet for that.. thanks in advance...
|
 |
Venkat Sadasivam
Ranch Hand
Joined: May 10, 2008
Posts: 139
|
|
<t:inputCalendar validator="#{bean.dateValidator}" value="#{bean.dateValue}" /> Your bean should have following method public void dateValidator(FacesContext facesContext, UIComponent uiComponent, Object newValue) { // perform your validation here }
|
 |
 |
|
|
subject: Validation For Tomahawk inputCalender Component
|
|
|