cannot catch NSValidation.ValidationException
cannot catch NSValidation.ValidationException
- Subject: cannot catch NSValidation.ValidationException
- From: Dumitru Husleag <email@hidden>
- Date: Wed, 9 Mar 2005 11:37:08 +0100
Hello everybody,
I have validateKey() methods in an EnterpriseObject. The code gets
caled (I see in the console the ERXLogger message : "Validation failed
on an object ...").
My code looks like this:
<code>
try{
ec.saveChanges();
}
catch(Throwable x){
setErrorMessage(x.getMessage());
}
</code>
The problem is I do not get an exception here. Wich means somebody
stoles my exception :)
So, who is the thief ???
I tried to put this before savechanges:
<code>
ec.setStopsValidationAfterFirstError(false);
ec.setDelegate(null);
</code>
Didnt solved my problem.
I can put all the validations in the validateForSave but I prefer
this way (validateKey method for each key).
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden