Embedding Java Applet in Oracle Form

I'd like to embed Java applet in Oracle Form. Please someone help me..let me know how to do it. Also I need to know how'll I use a jar within Oracle. Please help.
Regards
Rashed

Hi Grant
Thanks...I developed an applet which has a button on it and clicking the button something will happen. I mean this is a complete java project. Now I need to use this java applet from Oracle Form...that means I'll develop an oracle form on which the applet will be embedded so that the button on the applet can be pressed. Now could you please help me do this? I also have another problem but I need to resolve this first.
Rashed

Similar Messages

  • Urgent : Communicate from JAVA Applet to Oracle Forms

    Hi All,
    I have developed swing applet. Through this applet I need to start the Oracle Forms on web and access it as well. Is there a way to to this. In this case, Oracle Form is using Global Variables, and the requirement is to set these from my swing applet.

    Many thnx Frank.
    Still little confused. I am J2EE guys and hardly have any understanding on Oracle Forms. I am explaining the requirement in detail so as to you can get an insight into my issue.
    We have a developed a swing Applet, which would be access on web. We have received Oracle Forms from the client, and this has been installed on Oracle10gAS. Our application is installed on the same server. Once user starts interactions with the applet, it will be session based. Also the applet is running at the client end and the form would open at the client end as well. So how is this singleton going to benefit it.
    If the singleton in placed at the server end, how would be maintain the session?
    Can the solution you are mentioning, used in some way to implement SSO, although the login will be done through the applet?
    I am sorry to be a trouble, but if can possibly provide some code snippet, it would be of immense help.
    Thnx a million!
    Regards,
    Rajiv

  • Java.lang.ClassNotFoundException: oracle.forms.engine.Main

    I got this error when opening my forms, in java console, it says the frmall.jar file cannot be downloaded.
    I tried to get access the file with http://192.168.3.44:9001/forms/java/frmall.jar  ,  it displays 404 page not found.
    I think the virtual path defined in forms.conf is not working at all. Because I tried to put a html file under each of the directory, none of them are accessible.
    RewriteRule ^/forms/java/(..*) /workaroundjava/$1 [PT]
    AliasMatch ^/workaroundjava/(..*) "/home/oracle/Oracle/Middleware/Oracle_FRHome1/forms/java/$1"
    RewriteRule ^/forms/html/(..*) /workaroundhtml/$1 [PT]
    AliasMatch ^/workaroundhtml/(..*) "/home/oracle/Oracle/Middleware/asinst_1/config/FormsComponent/forms/html/$1"
    RewriteRule ^/forms/webutil/(..*) /workaroundwebutil/$1 [PT]
    AliasMatch ^/workaroundwebutil/(..*) "/home/oracle/Oracle/Middleware/Oracle_FRHome1/forms/webutil/$1"
    What might be the problem ?
    Here is the java console log :
    network: Cache entry not found [url: http://192.168.3.44:9001/forms/java/frmall.jar, version: null]
    network: Connecting http://192.168.3.44:9001/forms/java/frmall.jar with proxy=DIRECT
    java.io.FileNotFoundException: http://192.168.3.44:9001/forms/java/frmall.jar
      at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)
      at sun.plugin.PluginURLJarFileCallBack.downloadJAR(Unknown Source)
      at sun.plugin.PluginURLJarFileCallBack.access$000(Unknown Source)
      at sun.plugin.PluginURLJarFileCallBack$1.run(Unknown Source)
      at java.security.AccessController.doPrivileged(Native Method)
      at sun.plugin.PluginURLJarFileCallBack.retrieve(Unknown Source)
      at sun.net.www.protocol.jar.URLJarFile.retrieve(Unknown Source)
      at sun.net.www.protocol.jar.URLJarFile.getJarFile(Unknown Source)
      at sun.net.www.protocol.jar.JarFileFactory.get(Unknown Source)
      at sun.net.www.protocol.jar.JarURLConnection.connect(Unknown Source)
      at sun.plugin.net.protocol.jar.CachedJarURLConnection.connect(Unknown Source)
      at sun.plugin.net.protocol.jar.CachedJarURLConnection.getJarFileInternal(Unknown Source)
      at sun.plugin.net.protocol.jar.CachedJarURLConnection.getJarFile(Unknown Source)
      at com.sun.deploy.security.DeployURLClassPath$JarLoader.getJarFile(Unknown Source)
      at com.sun.deploy.security.DeployURLClassPath$JarLoader.access$1000(Unknown Source)
      at com.sun.deploy.security.DeployURLClassPath$JarLoader$1.run(Unknown Source)
      at java.security.AccessController.doPrivileged(Native Method)
      at com.sun.deploy.security.DeployURLClassPath$JarLoader.ensureOpen(Unknown Source)
      at com.sun.deploy.security.DeployURLClassPath$JarLoader.<init>(Unknown Source)
      at com.sun.deploy.security.DeployURLClassPath$3.run(Unknown Source)
      at java.security.AccessController.doPrivileged(Native Method)
      at com.sun.deploy.security.DeployURLClassPath.getLoader(Unknown Source)
      at com.sun.deploy.security.DeployURLClassPath.getLoader(Unknown Source)
      at com.sun.deploy.security.DeployURLClassPath.getResource(Unknown Source)
      at sun.plugin2.applet.Plugin2ClassLoader$2.run(Unknown Source)
      at java.security.AccessController.doPrivileged(Native Method)
      at sun.plugin2.applet.Plugin2ClassLoader.findClassHelper(Unknown Source)
      at sun.plugin2.applet.Applet2ClassLoader.findClass(Unknown Source)
      at sun.plugin2.applet.Plugin2ClassLoader.loadClass0(Unknown Source)
      at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
      at sun.plugin2.applet.Plugin2ClassLoader.loadClass0(Unknown Source)
      at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
      at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
      at java.lang.ClassLoader.loadClass(Unknown Source)
      at sun.plugin2.applet.Plugin2ClassLoader.loadCode(Unknown Source)
      at sun.plugin2.applet.Plugin2Manager.initAppletAdapter(Unknown Source)
      at sun.plugin2.applet.Plugin2Manager$AppletExecutionRunnable.run(Unknown Source)
      at java.lang.Thread.run(Unknown Source)
    basic: load: class oracle.forms.engine.Main not found.
    java.lang.ClassNotFoundException: oracle.forms.engine.Main
      at sun.plugin2.applet.Applet2ClassLoader.findClass(Unknown Source)
      at sun.plugin2.applet.Plugin2ClassLoader.loadClass0(Unknown Source)
      at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
      at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
      at java.lang.ClassLoader.loadClass(Unknown Source)
      at sun.plugin2.applet.Plugin2ClassLoader.loadCode(Unknown Source)
      at sun.plugin2.applet.Plugin2Manager.initAppletAdapter(Unknown Source)
      at sun.plugin2.applet.Plugin2Manager$AppletExecutionRunnable.run(Unknown Source)
      at java.lang.Thread.run(Unknown Source)
    Ignored exception: java.lang.ClassNotFoundException: oracle.forms.engine.Main
    basic: Dialog type is not candidate for embedding
    basic: Removed progress listener: sun.plugin.util.ProgressMonitorAdapter@1e966fb
    security: Reset deny session certificate store

    In your Forms/Java folder ensure that frmall.jar is present
    Also in your formsweb.cfg file add the jars in archive.

  • Java.lang.NoSuchMethodError: oracle.forms.handler.IHandler.getApplet()Ljava

    Hello to all
    I hope it is right forum for my question
    I have found for error I get in Directprint this following:
    When you migrate to the latest Forms version (10.1.2.3 or 11) and try using a JavaBean created with an older Forms version, you can get the following error, at runtime, in the Java Console:
    Exception in thread "thread applet-oracle.forms.engine.Main-1" java.lang.NoSuchMethodError: oracle.forms.handler.IHandler.getApplet()Ljava/applet/Applet
    The reason is you try to use a Java Bean compiled with an older Forms JAR file, like f90all.jar.
    So, to correct the issue, you have to change the Java code then re-create the JAR file:
    private Main formsMain = null;
    Replace:
    formsMain = (Main) handler.getApplet();
    by:
    // getting the Forms Main class
    try{
    Method method = handler.getClass()
    .getMethod("getApplet", new Class[0]);
    Object applet = method.invoke(handler, new Object[0]);
    if (applet instanceof Main) {
    formsMain = (Main)applet;
    }catch(Exception ex) {;}
    Then create and deploy the new JAR file to your /forms/Java folder.
    My problem is
    But I am very poor in java code, could you guide me to do what that article said, or pointing me where find instruction how do this following
    So, to correct the issue, you have to change the Java code then re-create the JAR file:Can I create Jar Directprint.jar, with command
    jar cf jar-file input-file(s)
    C:\DevSuiteHome_1\jdk\bin\jar cvf DirectPrint.jar DirectPrint.java
    Because when I open jdeveloper to associate (Creating JAR deployments using JDeveloper ) it got error (jdeveloper with debug
    Thanks for any help

    I hope it is right forum for my questionIt's not {noformat}:){noformat}
    Try {forum:id=82}
    Best,
    john

  • Java class in oracle forms

    Hello experts,
                        I am new in oracle forms.I am using oracle forms 11g with weblogic 10.3.5 at windows 7.Someone please clear me that the injection of java programing in oracle forms is through BEANS item only or I can use it(java class) as a part of my oracle forms.I mean I have a Java class.Could I use this java class inside my oracle forms without using Beans Item.
    Thank You
    regards
    aaaditya

    In forms you can use java in two different ways
    1. On the client-side. Using java-beans you can extend the client-functionality of forms. The code will run on the client-computer in the context of the applet.
    2. On the server-side. Using the java-importer you can build a PL/SQL-wrapper around a java-class and so use the java-code in your forms-PL/SQL
    What is your reuqirement?

  • Error while importing java class into oracle forms 10g

    Hi
    I have generated a web service client using jdeveloper 10g. It consists of complex type methods. I am trying to import the class files using java importer in oracle form 10g. I am able import all of them successfully except one. That one is the main method. Please see the error and suggest me how to overcome this error.
    Exception occurred: java.lang.NoClassDefFoundError: oracle/jdeveloper/webservices/runtime/WrappedDocLiteralStub
    Thanks in advance

    Do you see oracle/jdeveloper listed in "Import Java Classes" when you try to import?
    If not, make sure you add C:\DevSuiteHome_1\jdev\lib\jdev.jar to FORMS_BUILDER_CLASSPATH in registry
    Also excetion indicates: oracle/jdeveloper/webservices/runtime/WrappedDocLiteralStub
    If you typing it - type: oracle.jdeveloper.webservices.runtime.WrappedDocLiteralStub

  • How to use Java Script in Oracle Forms 10g

    Hello,
    Appreciate if anyone could help me using Java Script in Oracle Forms 10g?
    Thanks
    GM

    Thank you for your reply. I was reading on the metalink that we could use the to call the java script from oracle Forms 10g (Doc ID 265863.1)
    Example:
    WEB.SHOW_DOCUMENT ('javascript:void(window.open("http://www.oracle.com","","location=no,toolbar=no,menubar=no,status=no,"));self.close()','_blank');
    I tried it but it did not open the any window as it claims. Am I missing anything? Is there any IE related setting which I need to modify for the above to work?
    Regards
    GM

  • Help : Unable to use Java Beans in Oracle forms 6i

    Hi ,
    I have been trying to run few sample code to understand how to use Java beans in oracle forms 6i .But have been largely unsuccessfull.
    It will be great if somebody can provide me with some simple form( and java code )which uses java beans concept to give some data to the java program and receive some data from it . Pls inform me about the settings that need to be done.
    If you guys know it then pls take the pains of writing a simple form and java code.
    i hope somebody will respond because your reply is very necesary for me to proceed.
    U can email me the code > [email protected]
    Thanks in advance.

    Thanks for your reply Francois.
    Actually i am not facing problem understanding the programming technique.
    I think the problem at my end is more of a cofiguration one.I am using forms version 6i
    on oracle 8.
    Every time i set the imlementation class property of the bean area it gives an error 13010 which translates to that "the class being mentioned is not extending the IView class".
    The class i have written extends VBean so i am not sure why this error is occuring.
    I think if oracle (correctly) finds the java class to use then i will be able to proceed.
    Pls reply.
    If you have some code that is working fine then pls send it to me.And also inform is some environment variables have to be set for its use.

  • Embedded Java applet no longer works correctly (works is old FFOX, Goggle Crome, etc.)

    an embedded Java applet pops up a response box with success or failure on a dbms update. With FFOX(32) 8.x and 9.x running on win7 64, the response box is blank but it should always be either Success or Failed.
    This works just fine in older FFox(with XP), Goggle Chrome(win7 64), etc.

    Hi and Welcome to the Forums!
    Anytime random strange behaviors creep in, the first thing to do is a battery pop reboot. With power ON, remove the back cover and pull out the battery. Wait about a minute then replace the battery and cover. Power up and wait patiently through the long reboot -- ~5 minutes. See if things have returned to good operation. Like all computing devices, BB's suffer from memory leaks and such...with a hard reboot being the best cure.
    Best!
    Occam's Razor nearly always applies when troubleshooting technology issues!
    If anyone has been helpful to you, please show your appreciation by clicking the button inside of their post. Please click here and read, along with the threads to which it links, for helpful information to guide you as you proceed. I always recommend that you treat your BlackBerry like any other computing device, including using a regular backup schedule...click here for an article with instructions.
    Join our BBM Channels
    BSCF General Channel
    PIN: C0001B7B4   Display/Scan Bar Code
    Knowledge Base Updates
    PIN: C0005A9AA   Display/Scan Bar Code

  • Problem of calling the applet by Oracle Form

    Hi,
    The oracle form invokes a applet function, and send one parameter to the applet. The parameter will be displayed in the applet correctly at the first time.
    But if the user do not close the applet and use invoke the applet function again, the applet cannot show the latest parameter and keep show the old one.
    Please give me some adive.
    Thanks

    Hi,
    This is a JDeveloper help forum, the Formsforum can be found at Forms Now you might think that Forms developers don't understand Java well enough, they do however understand teh Forms context and this is important to answr the question.
    a) Which Java version does your ben require?
    b) Are you using JInitiator or JavaPlugin (Jinitiator only supports Java 1.3)
    c) Is your PJC signed? Note that running an app stand alone as a Java app does not require special grants. Running it within a JavaApplet - as Forms is - does execute teh bean in a security sandbox, for which reasons the jar file must be signed and the public key be available in the Forms certdb.txt file (assuming Jinitiator)
    d) An exception stack trace gives more information than "Oracle Form it doesn't run and exception is thrown on javax.imageio and other packages", which is meanlingless to me and others. Teh stack trace canbe copied from teh JInitiator console
    I recommend resending this question to the Forms forum
    Frank

  • Calling Java screens from Oracle Forms application

    I am working with a client that has a large Oracle forms application. Since rewriting the entire application in Java is not an option at this time, the strategic direction is that any new modules that are to be created for the application are to be done in Java and called from the Forms menu. The decision as to what tool to use to develop the Java modules is still under debate. What is the best (most seamless) way to do this...calling a Java screen from a Forms application? If anyone has any experience in this, or can direct me to some literature on it, it would be greatly appreciated. Thanks.

    This is a web app in Forms/Reports 10g R2 running off Oracle AS and an Oracle db. The challenge for us is that the direction is that any new enhancements (screens) are to be built using Java (in either ADF Faces or Swing, another point for debate later) and then called from the Forms app. The business client is only paying for the enhancement. They don't care about moving off Forms to Java, so any extra work on the part of IT to do this, has to be fairly minimal and doable within the project budget. The movement to Java is an IT direction. Is there a way to do this without having to build a java framework for the entire Forms application (which I assume would take some time and involve retesting the entire app)?

  • How to use java programe in oracle form

    Hello Expert,
    My Config is : -
    Forms [32 Bit] Version 11.1.1.3.0 (Production)
    Jdeveloper - 10.1.3
    I want to use the java programe in form builder. I create the one java class in Jdeveloper -
    package demo;
    import java.net.InetAddress;
    import java.net.NetworkInterface;
    import java.net.SocketException;
    import java.net.UnknownHostException;
    public class get_info{
       public static void main(String[] args){
       ch_add();
       public static void ch_add()
      InetAddress ip;
      try { 
      ip = InetAddress.getLocalHost();
      /*System.out.println("Current IP address : " + ip.getHostAddress());  */
      NetworkInterface network = NetworkInterface.getByInetAddress(ip);
      byte[] mac = network.getHardwareAddress();
      /*System.out.print("Current MAC address : ");   */
      StringBuilder sb = new StringBuilder();            
      for (int i = 0; i < mac.length; i++)
      sb.append(String.format("%02X%s", mac[i], (i < mac.length - 1) ? "-" : ""));
      System.out.println(sb.toString()); 
      } catch (UnknownHostException e) {
      e.printStackTrace();
      } catch (SocketException e){
      e.printStackTrace();
    and this into Formweb.cfg and default.env and also add into Form_class_path. After that i import this java into forms.
    Code genertated -
    PACKAGE BODY get_info IS
      -- DO NOT EDIT THIS FILE - it is machine generated!
      args   JNI.ARGLIST;
      -- Constructor for signature ()V
      FUNCTION new RETURN ORA_JAVA.JOBJECT IS
      BEGIN
        args := NULL;
        RETURN (JNI.NEW_OBJECT('demo/get_info', '()V', args));
      END;
      -- Method: main ([Ljava/lang/String;)V
      PROCEDURE main(
        a0    ORA_JAVA.JARRAY) IS
      BEGIN
        args := JNI.CREATE_ARG_LIST(1);
        JNI.ADD_OBJECT_ARG(args, a0, '[Ljava/lang/String;');
        JNI.CALL_VOID_METHOD(TRUE, NULL, 'demo/get_info', 'main', '([Ljava/lang/String;)V', args);
      END;
      -- Method: ch_add ()V
      PROCEDURE ch_add IS
      BEGIN
        args := NULL;
        JNI.CALL_VOID_METHOD(TRUE, NULL, 'demo/get_info', 'ch_add', '()V', args);
      END;
      -- Method: wait (J)V
      PROCEDURE wait(
        obj   ORA_JAVA.JOBJECT,
        a0    NUMBER) IS
      BEGIN
        args := JNI.CREATE_ARG_LIST(1);
        JNI.ADD_LONG_ARG(args, a0);
        JNI.CALL_VOID_METHOD(FALSE, obj, 'demo/get_info', 'wait', '(J)V', args);
      END;
      -- Method: wait ()V
      PROCEDURE wait(
        obj   ORA_JAVA.JOBJECT) IS
      BEGIN
        args := NULL;
        JNI.CALL_VOID_METHOD(FALSE, obj, 'demo/get_info', 'wait', '()V', args);
      END;
      -- Method: wait (JI)V
      PROCEDURE wait(
        obj   ORA_JAVA.JOBJECT,
        a0    NUMBER,
        a1    NUMBER) IS
      BEGIN
        args := JNI.CREATE_ARG_LIST(2);
        JNI.ADD_LONG_ARG(args, a0);
        JNI.ADD_INT_ARG(args, a1);
        JNI.CALL_VOID_METHOD(FALSE, obj, 'demo/get_info', 'wait', '(JI)V', args);
      END;
      -- Method: equals (Ljava/lang/Object;)Z
      FUNCTION equals(
        obj   ORA_JAVA.JOBJECT,
        a0    ORA_JAVA.JOBJECT) RETURN BOOLEAN IS
      BEGIN
        args := JNI.CREATE_ARG_LIST(1);
        JNI.ADD_OBJECT_ARG(args, a0, 'java/lang/Object');
        RETURN JNI.CALL_BOOLEAN_METHOD(FALSE, obj, 'demo/get_info', 'equals', '(Ljava/lang/Object;)Z', args);
      END;
      -- Method: toString ()Ljava/lang/String;
      FUNCTION toString(
        obj   ORA_JAVA.JOBJECT) RETURN VARCHAR2 IS
      BEGIN
        args := NULL;
        RETURN JNI.CALL_STRING_METHOD(FALSE, obj, 'demo/get_info', 'toString', '()Ljava/lang/String;', args);
      END;
      -- Method: hashCode ()I
      FUNCTION hashCode(
        obj   ORA_JAVA.JOBJECT) RETURN NUMBER IS
      BEGIN
        args := NULL;
        RETURN JNI.CALL_INT_METHOD(FALSE, obj, 'demo/get_info', 'hashCode', '()I', args);
      END;
      -- Method: getClass ()Ljava/lang/Class;
      FUNCTION getClass(
        obj   ORA_JAVA.JOBJECT) RETURN ORA_JAVA.JOBJECT IS
      BEGIN
        args := NULL;
        RETURN JNI.CALL_OBJECT_METHOD(FALSE, obj, 'demo/get_info', 'getClass', '()Ljava/lang/Class;', args);
      END;
      -- Method: notify ()V
      PROCEDURE notify(
        obj   ORA_JAVA.JOBJECT) IS
      BEGIN
        args := NULL;
        JNI.CALL_VOID_METHOD(FALSE, obj, 'demo/get_info', 'notify', '()V', args);
      END;
      -- Method: notifyAll ()V
      PROCEDURE notifyAll(
        obj   ORA_JAVA.JOBJECT) IS
      BEGIN
        args := NULL;
        JNI.CALL_VOID_METHOD(FALSE, obj, 'demo/get_info', 'notifyAll', '()V', args);
      END;
    BEGIN
      NULL;
    END;
    Now i want to call the o/p of Java programe in oracle text item. Please help me. It's very urgent. I am not good in Java.

    Sir i use java importer.
    PACKAGE BODY get_info IS
      -- DO NOT EDIT THIS FILE - it is machine generated!
      args   JNI.ARGLIST;
      -- Constructor for signature ()V
      FUNCTION new RETURN ORA_JAVA.JOBJECT IS
      BEGIN
        args := NULL;
        RETURN (JNI.NEW_OBJECT('demo/get_info', '()V', args));
      END;
      -- Method: main ([Ljava/lang/String;)V
      PROCEDURE main(
        a0    ORA_JAVA.JARRAY) IS
      BEGIN
        args := JNI.CREATE_ARG_LIST(1);
        JNI.ADD_OBJECT_ARG(args, a0, '[Ljava/lang/String;');
        JNI.CALL_VOID_METHOD(TRUE, NULL, 'demo/get_info', 'main', '([Ljava/lang/String;)V', args);
      END;
      -- Method: ch_add ()V
      PROCEDURE ch_add IS
      BEGIN
        args := NULL;
        JNI.CALL_VOID_METHOD(TRUE, NULL, 'demo/get_info', 'ch_add', '()V', args);
      END;
      -- Method: wait (J)V
      PROCEDURE wait(
        obj   ORA_JAVA.JOBJECT,
        a0    NUMBER) IS
      BEGIN
        args := JNI.CREATE_ARG_LIST(1);
        JNI.ADD_LONG_ARG(args, a0);
        JNI.CALL_VOID_METHOD(FALSE, obj, 'demo/get_info', 'wait', '(J)V', args);
      END;
      -- Method: wait ()V
      PROCEDURE wait(
        obj   ORA_JAVA.JOBJECT) IS
      BEGIN
        args := NULL;
        JNI.CALL_VOID_METHOD(FALSE, obj, 'demo/get_info', 'wait', '()V', args);
      END;
      -- Method: wait (JI)V
      PROCEDURE wait(
        obj   ORA_JAVA.JOBJECT,
        a0    NUMBER,
        a1    NUMBER) IS
      BEGIN
        args := JNI.CREATE_ARG_LIST(2);
        JNI.ADD_LONG_ARG(args, a0);
        JNI.ADD_INT_ARG(args, a1);
        JNI.CALL_VOID_METHOD(FALSE, obj, 'demo/get_info', 'wait', '(JI)V', args);
      END;
      -- Method: equals (Ljava/lang/Object;)Z
      FUNCTION equals(
        obj   ORA_JAVA.JOBJECT,
        a0    ORA_JAVA.JOBJECT) RETURN BOOLEAN IS
      BEGIN
        args := JNI.CREATE_ARG_LIST(1);
        JNI.ADD_OBJECT_ARG(args, a0, 'java/lang/Object');
        RETURN JNI.CALL_BOOLEAN_METHOD(FALSE, obj, 'demo/get_info', 'equals', '(Ljava/lang/Object;)Z', args);
      END;
      -- Method: toString ()Ljava/lang/String;
      FUNCTION toString(
        obj   ORA_JAVA.JOBJECT) RETURN VARCHAR2 IS
      BEGIN
        args := NULL;
        RETURN JNI.CALL_STRING_METHOD(FALSE, obj, 'demo/get_info', 'toString', '()Ljava/lang/String;', args);
      END;
      -- Method: hashCode ()I
      FUNCTION hashCode(
        obj   ORA_JAVA.JOBJECT) RETURN NUMBER IS
      BEGIN
        args := NULL;
        RETURN JNI.CALL_INT_METHOD(FALSE, obj, 'demo/get_info', 'hashCode', '()I', args);
      END;
      -- Method: getClass ()Ljava/lang/Class;
      FUNCTION getClass(
        obj   ORA_JAVA.JOBJECT) RETURN ORA_JAVA.JOBJECT IS
      BEGIN
        args := NULL;
        RETURN JNI.CALL_OBJECT_METHOD(FALSE, obj, 'demo/get_info', 'getClass', '()Ljava/lang/Class;', args);
      END;
      -- Method: notify ()V
      PROCEDURE notify(
        obj   ORA_JAVA.JOBJECT) IS
      BEGIN
        args := NULL;
        JNI.CALL_VOID_METHOD(FALSE, obj, 'demo/get_info', 'notify', '()V', args);
      END;
      -- Method: notifyAll ()V
      PROCEDURE notifyAll(
        obj   ORA_JAVA.JOBJECT) IS
      BEGIN
        args := NULL;
        JNI.CALL_VOID_METHOD(FALSE, obj, 'demo/get_info', 'notifyAll', '()V', args);
      END;
    BEGIN
      NULL;
    END;
    I read both document which is given by you.
    Basicaly i don't know how to call java program in form builder.
    I wrote this code on When-button-pressed
    DECLARE
    jo ora_java.jobject;
    rv varchar2(1500);
    ex ora_java.jobject;
    BEGIN
    jo := get_info.new;
    rv:=get_info.ch_add(jo );
    EXCEPTION
    WHEN ORA_JAVA.JAVA_ERROR then
      message (' Unable to call out to Java, ' ||ORA_JAVA.LAST_ERROR );
      message('');
    WHEN ORA_JAVA.EXCEPTION_THROWN then
      ex := ORA_JAVA.LAST_EXCEPTION;
      message(' Unable to call out to Java ' ||Exception_.toString (ex ) );
      message(' Unable to call out to Java ' ||Exception_.toString (ex ) );
    END;
    No error comes and no output comes. I want the client MAC ID. please guide me where i need to change the code.

  • How to use Java Beans in Oracle Forms 11g at 64 bit windows7

    Hello Experts,
                  I am using Oracle forms 11.1.2.2.0 with weblogic 10.3.6 generic at windows 7 64 bit.
    My java version is jdk1.7.0_51.
    Now I have a htmlbutton.jar (which is for bean item in oracle form and this jar file works well for oracle forms 11g 32 bit windows 7 environment).
    I have takken steps:
    1:-Put jar file in home\java folder.
    2:-add this jar file into archive in formsweb.cfg.
    3:-Add this this jar file(which is in my home- java folder) in form_class path in registry.
    Now when I try to locate this jar file in my oracle form.There is no such jar file.what are the steps to use this jar file in oracle forms bean item.
    Please told me what is wrong here.
    thank you
    regards
    aaditya.

    It is unclear where you are having a problem.  Is your issue at runtime (when the form runs in the browser) or when working in the Builder on the form?
    Also be aware that you will need to sign your jar and include some new manifest entries.  Refer to the Java 7u51 documentation and blogs that discuss the changes.
    https://blogs.oracle.com/java-platform-group/entry/new_security_requirements_for_rias
    http://docs.oracle.com/javase/7/docs/technotes/guides/jweb/manifest.html

  • Import Java Classes - How manipulate Java List in Oracle Form

    Good afternoon,
    I call a Web Service from Oracle Application Server 10g Forms Services but the object returned by the method is a java list. I created a stub/skeleton with JDeveloper and the communication between WebService and Oracle form works fine. The problem is how to desencapsulate the list within ORA_JAVA. I imported java.util.List it does not solve my problem.
    Method called: public List DecryptToken(Context context, String token) throws Exception
    This list will have in List.get(0) -> Context object
    List.get(1) -> String
    List get(2) -> String
    List get(3) -> Param []
    Thanks for your help.
    best regards,
    TT

    hi,
    try java stored procedure loop ur java list and get data in "type table" of requried data type
    and use it as u desired.
    piyush

  • How to call java function in Oracle forms?

    Hi I am having Oracle 9i with 10g Developer Suite.
    I am new to Oracle forms..
    I had one function in java getDatas()..
    How can I call this function in Oracle Forms..
    Pls help
    Thanks

    Thanks Francois,
    I want to display values from my java code in the Forms..
    For that purpose only i am installing 10g Developer Suite..
    The below is java code..
    public class DBTest {
              public static String callDB(int id,String name){
              String ss="Hai";
              Connection con=null;
              try{
                   Class.forName("oracle.jdbc.driver.OracleDriver");
                   con = DriverManager.getConnection("url","id","pwd");
                   Statement st=con.createStatement();
                   System.out.println("Connected...");
              int r=st.executeUpdate("Insert into FORM_TEST VALUES('"+id+"','"+name+"')");
                   if(r==1){
                        ss="Inserted Sucessfully";
                   else{
                        ss="Insertion Failed";
              }catch(final Exception e){
              System.out.println(e);
              return ss;
         public static void main(String[] args) {
              int empid=102;
              String empname="Gilbert";
              String resultStr=callDB(empid,empname);
              System.out.println(resultStr);
    I want to dispaly Inserted or Insertion Failed in Oracle Forms..
    As per Gerd Volberg suggestion, i had placed DBTest.jar in
    E:\DevSuite\forms\java\DBTest.jar
    and in formsweb.cfg the below jar is added..
    archive_jini=frmall_jinit.jar,DBTest.jar
    But in Fomrs Builder-->Program-->Import Java Classes-->Oracle
    org,ice,com and subnodes are available.
    But my jar is not available..
    Is my way is coorect?
    Pls provide soln..
    Thanks

Maybe you are looking for