Skip to Main Content

Java Development Tools

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Problems Validating an Attribute of type oracle.jbo.domain.date

406712Nov 12 2003 — edited Nov 17 2003
I have a form that has a date input field. I am trying to customise the exception error for this field for when the user enters something other than my dd/MM/yyyy format. ie JBO-25009: oracle.jbo.domain.DataCreationException

This Attribute uses a the oracle.jbo.domain.date data type. An exception is finally thrown when the transaction trys to commit.

My problem is that I can't customise the exception because I can't catch where it is occuring. I have tried at the <setAttributeInternal>, <setAttribute> and <validateEntity> levels uses both try{}catch(Jbo Exception){} and try{}catch(AttrValException){}. I believe the reason for this is because the problem occurs because the parse value to functions are invalid dates so it never enters them.

If this is true validation and any exception thrown should occur at the data type level, but the the oracle.jbo.domain.date class doesn't have a validate method.

Can someone please help me get around this problem. Or tell me if the have a solution for date input validation.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 15 2003
Added on Nov 12 2003
4 comments
304 views