setting error message to label
yourComponent.clearErrorMessage();
best
Stephan
hai stephan
as you said and as i required
if i take
Label quetionLabel=new Label();
quetionLabel.clearErrorMessage();
but there is no method for Label clearErrorMessage() .beacuse it is not an input element .if i worte that method it is asking for cast to InputElement then showing canot cast from label to input element .
Again i am explaining my issue
Label questionDesctionLabel=new Label();
throw new WrongValueException(questionDesctionLabel ,Labels.getLabel("label_ChecList_Must_SelectAnswer"));
here i can see error message ,now i have to remove it with out closing error meassage manually .error message should be cleared automatically by some method of label
where setErrorMessage(),clearErrorMessage() are not for the Label
Hi ommpavan,
not tested but have a try with a little trick. Put a very small input component right next the label and let these comp show the errorMessage.
By playing with the css style you can made it nearly invisible.
<hbox>
<label/>
<textbox width="1px" />
</hbox>
best
Stephan
Finally i have done with Textbox only .but if i can clear the error message of Label it should sounds good.Thank you sthephan .ZK ....Rocks
I guess you can clear the error message from any component using
Clients.clearWrongValue(Component comp);
I'm using ZK 5.0.9
best
Fonz
ZK - Open Source Ajax Java Framework
hai
Assume i have a Question description as Label and answers as Radiogroup .when if user dont selecting answer i am throwing wrong value exception to the label .
like
throw new WrongValueException(questionDesctionLabel
,Labels.getLabel("label_ChecList_Must_SelectAnswer"));
it is working fine but after selecting answer then rise save button the error message is still not clearing even i selected answer .for textboxes we made it usingtextbox.setErrorMeassage(" ") then how to remove error message for label which produced by worngvalue exception.
please replay fast i need it very urgent