Home » Developer & Programmer » Forms » Java in Forms: Exception_.toString
Java in Forms: Exception_.toString [message #526303] Mon, 10 October 2011 08:24 Go to next message
jb_vincennes
Messages: 5
Registered: August 2007
Location: Paris
Junior Member
Hi,

I have to implement exception handling in the exception block of a trigger, Quote:
exception
when ora_java.java_error then
message( 'Unable to call out to java, ' || ora_java.last_error );
ORA_JAVA.CLEAR_EXCEPTION;

when ORA_JAVA.EXCEPTION_THROWN then
ex := ORA_JAVA.LAST_EXCEPTION;
message( Exception_.toString(ex));
-- lv_exception := Exception_.getMessage(ex);


I get an error for the line: 'message( Exception_.toString(ex));'

I have imported the java classes FException et IObject with their methods.

I have to create a Web Service Client, so I wonder if the paragraph Quote:
when ORA_JAVA.EXCEPTION_THROWN then
ex := ORA_JAVA.LAST_EXCEPTION;
is mandatory.

Many thanks

Re: Java in Forms: Exception_.toString [message #526528 is a reply to message #526303] Tue, 11 October 2011 08:28 Go to previous messageGo to next message
jb_vincennes
Messages: 5
Registered: August 2007
Location: Paris
Junior Member
Hi

I have searched the Metalink bugs database and I have found that I need to import the "java.lang.Exception" class into the Forms / Programs / Import Java dialog box.

This class is not available in the tree.

I had to type java.lang.Exception in the field in the dialog box.

Now my trigger compiles.

Re: Java in Forms: Exception_.toString [message #526539 is a reply to message #526528] Tue, 11 October 2011 09:09 Go to previous message
cookiemonster
Messages: 13931
Registered: September 2008
Location: Rainy Manchester
Senior Member
Thanks for letting us know.
Previous Topic: How to complete this query?
Next Topic: Master detail form [merged 3]
Goto Forum:
  


Current Time: Sun Aug 11 09:41:47 CDT 2024