Problems creating a Java Array using JNI-HELP!

Hi,
I am trying to create a Java Array using JNI.I have posted the code below. The problem is that the oth element is added correctly to the Array but when the JVM gets to the next element...it goes for a toss. It is not able to create a new instance of the object in GetUGEntity() function...there seems to be some problem in creating a new instance of the object!
Can somebody help me with this?
jobject GetUGEntity(JNIEnv *env, UF_DISP_j3d_entity_t* entity_list)
     int numVerts=0, numStrips=0;
     jfieldID fid;
     jdoubleArray jTransform=NULL;
     jstring jstrName=NULL;
     jdoubleArray jNormals=NULL;
     //Init an Entity object
     cout<< "**Getting New Class Reference...";
     jclass jEntity = env->FindClass("Lcom/wipro/java3d/rmi/Entity;");
     cout << "**got Class reference..."<<endl;
     if (jEntity == NULL)
          return NULL;
     cout<<"Creating new object instance...";
     jmethodID mIDInit = env->GetMethodID(jEntity, "<init>", "()V");
     cout<<"Got java method id...";
     jobject javaObj = env->NewObject(jEntity, mIDInit);
     if (javaObj==NULL)
          return NULL;
     cout << "Created!" << endl;
     //Entity ID
     cout<< "**Setting eid...";
     fid=env->GetFieldID(jEntity,"eid","I");
     jint eid = (jint)(entity_list)->eid;
     env->SetIntField(javaObj, fid, eid);
     //env->DeleteLocalRef(eid);
     cout << "Done!" << endl;
     cout << "Done!" << endl;
     cout<< "**Returning jobject...";
     return javaObj;
jobjectArray createJArray(JNIEnv* env, UF_DISP_j3d_entity_t** entity_list, int noOfEntities )
     UF_DISP_j3d_entity_t* tempVar=NULL;
     cout<<"*Creating Jobjectarray...";
     jobjectArray jEntityArray = (jobjectArray) env->NewObjectArray(noOfEntities,
          env->FindClass("Lcom/wipro/java3d/rmi/Entity;"),NULL);
     cout<<"Created!"<<endl;
     for(int i=0; i<noOfEntities;++i)
          tempVar = &(*entity_list);
          if (tempVar !=NULL)
               cout<<"*Trying to get Entity...."<<endl;
               jobject jEntity = GetUGEntity(env, tempVar);
               if (jEntity!= NULL)
                    cout<<"Got Entity!" <<endl;
                    cout <<"*Setting Array Element....";
                    env->SetObjectArrayElement(jEntityArray, i, jEntity);
                    cout << "Done!" << endl;
               else
                    printf("ERROR: Did not get Entity Reference");
          else
               printf("ERROR: Got a NULL Reference!");
     return jEntityArray;

Hi Deepak,
Could you please let us know upto which line your code is going safe. Try printing the value in the structure before you send that to the method GetUGEntity().
I am not too sure that would be a problem. But I have faced a problem like this, wherein I tried to access a structure for which I have not allocated memory and hence got exception because of that.
Since your JNI code seems to be error free, I got doubt on your C part. Sorry.
Dhamo.

Similar Messages

  • Problems Creating a Java Class using a webservice with certificate

    hi,
    i'm developing a java class that call's a webservice that needs a certificate, i'm not used to work with java, last time was 10 years ago, so i'm having some troubles because of the certificate.
    I already add the certificate using java control panel > Security > Certificates. When testing i get the following error: IOException (java.io.IOException: subject key, Unknown key spec)
    I think I need to define the certificate in my class, but i'm having a lots of trouble with the samples that i found over the internet, nothing works and i'm running out of time.
    This is my Class
    create or replace and compile java source named "FishInfoAt" as
    import java.net.*;
    import java.io.*;
    import java.security.*;
    public class FishInfoAt
         public FishInfoAt()
         public static String send(String urlfishinfoat, String mensagem, String mensagem1, String mensagem2, String mensagem3)
              // Init
              String response = "";
              String msgtotal = mensagem+mensagem1+mensagem2+mensagem3;
              String a = "";
              HttpURLConnection conn = null;
              try{
                   URL url = new URL(urlfishinfoat);
                   conn = (HttpURLConnection) url.openConnection();
                   conn.setRequestMethod("POST");
                   conn.setRequestProperty("Content-type", "text/xml; charset=utf-8");
                   conn.setRequestProperty("SOAPAction", "https://servicos.portaldasfinancas.gov.pt:401/sgdtws/documentosTransporte/");
                   conn.setRequestProperty("Content-Length","" + msgtotal.length());
                   conn.setDoOutput(true);
                   conn.setDoInput(true);
                   conn.connect();
                   OutputStream out = conn.getOutputStream();
                   out.write(msgtotal.getBytes());
                   out.flush();
                   InputStream in = conn.getInputStream();
                   int value;
                   while( (value = in.read()) != -1)
                        response+=(char)value;
              catch(Exception e)
    response = ("*** ERROR - IOException (" + e.getMessage() + a + ")");
    return response;
    /

    Hi Deepak,
    Could you please let us know upto which line your code is going safe. Try printing the value in the structure before you send that to the method GetUGEntity().
    I am not too sure that would be a problem. But I have faced a problem like this, wherein I tried to access a structure for which I have not allocated memory and hence got exception because of that.
    Since your JNI code seems to be error free, I got doubt on your C part. Sorry.
    Dhamo.

  • Can not locate Java class using JNI within C++ DLL

    I am using trying to use JNI to call a Java class from C++. The Java class uses JMS to send messages to a JMS message queue. At first I coded the C++ in a console application that created the JavaVM and used JNI to access the Java class. All worked fine. Then I called the Java class using JNI from threads and ran into the problem of the Java class not able to locate the JMS related classes. This was solved by placing the following line in the constructor of the Java class.
    Thread.currentThread().setContextClassLoader(ClassLoader.getSystemClassLoader());
    Then I moved the JNI code from a console application to a DLL in specific an extension DLL that is called by SQL Server or Oracle server. The DLL will use JNI to call the Java class and send messages to a JMS message queue.
    The problem I am having now when the DLL code is called by SQL Server the call to
    JNI_CreateJavaVM
    appears to work correctly but the call to find the Java class using
    jvmEnv->FindClass(pName)
    fails. It appears the is a class loading problem which occurs due to the fact JNI is called from a DLL. When the VM is created I pass the class path information using the statement
    -Djava.class.path=
    And as I stated before it all works when running from a console application. I am new to JNI and really need help in the form of some sample code that will solve this problem. I believe I need to somehow load the classpath information from the DLL but I can not find examples on how to do this using JNI. I have tried several ways using URLClassLoader and getSystemClassLoader from JNI and either it does not work or it crashes very badly.
    I used the following code to determine what the existing class path is and the string returns empty.
    jcls = jvmEnv->FindClass("java/lang/System");
    jmid = jvmEnv->GetStaticMethodID(jcls, "getProperty", "(Ljava/lang/String;)Ljava/lang/String;");
    jstrClassPath = jvmEnv->NewStringUTF("java.class.path");
    jstr = (jstring)jvmEnv->CallStaticObjectMethod(jcls, jmid, jstrClassPath);
    m_jstr = (jstring)jvmEnv->NewGlobalRef(jstr);
    pstr = jvmEnv->GetStringUTFChars(m_jstr, 0);
    Can anyone please help with example code that will solve this problem. Thanks in advance for any help.
    Charles�

    I have determined the problem occurs when the application/component is compiled using VC 6.0. The test application was compiled using VC 7.1 and works correctly by locating the class path information. If the test application is compiled using VC 6.0 it has the same problem.
    The jvm.dll I am using is version 1.4.2.80. Currently this is not an option to compile all the applications that use JNI using VC 7.1 so can someone please tell me how to solve this problem.

  • How can i call a VB6 project from my java application using JNI

    hi
    can anyone tell me the procedure of calling a VB6 project from any java application using JNI
    if anyone does know then tell me the detail procedure of doing that. I know that i have to create a dll of that VB6 project then to call it from the java application.
    if anyone know that procedure of creating dll file of an existing VB6 project please reply
    please if anyone know then let me know

    Ahh, kind of a duplicate thread:
    http://forums.java.sun.com/thread.jspa?threadID=631642
    @OP. You could have clarified your original post and the relationship of your question to java. You did not need a new thread.
    � {�                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • How to instantiate a java object (using JNI)?(n'more)

    hey bschauwe, thanks for your last post, you were guessing but your 4th guess was right on the money of how id like to do it.
    "4. An alternative way to return data to java from C is to instantiate a java object (using JNI), then use JNI to call that object's setters, then return the object at the end of the C routine."
    I know now how to get the object's setters, I am just unsure how to instantiate a java object from the native C code using JNI. Also you said to returnt he object at the end of the c routine, that is just a good ol' return statement right? no other functions to release memory or anything are needed? So basically it would be something like:
    JNIEXPORT jobject retObj JNICALL Java_AbfaRegion_getJSourceData
      (JNIEnv *env, jobject thisObj)
            //instantiate the java object on retObj????
            //call setters with values from the c structures...
            //return retObj??? no other memory releasing needed?
    }Thanks again for all your help,
    Shane

    K sounds straight forward enough, the index in my book had nothing on <init> and I wasnt aware of the NewObject call. So my final (well for demonstration purposes) code should look something like:
    JNIEXPORT jobject retObj JNICALL Java_AbfaRegion_getJSourceData
      (JNIEnv *env, jobject thisObj)
         jclass clazz;
         jclass clazzTemp;
         jmethodID mid;
         jint val;
         jobject tempObj;
            //first instanciate the object
         clazz = (*env)->GetObjectClass(env, retObj);
         mid  = (*env)->GetMethodID(env, clazz, "<init>", "()V");     
            //Get Object
         tempObj = (*env)->NewObject(env, clazz, mid);
            //get Class reference to instantiated class
         clazzTemp = (*env)->GetObjectClass(env, tempObj);
            //Start calling setters to set the object up.
         mid = (*env)->GetMethodID(env, clazzTemp, "SetHeight", "(I)V");
         (*env)->CallVoidMethod(env,tempObj, mid, struct->myHeight);
            //set more members ...
            //return the object back to java with its members filled out.
            //before returning do I need to call (*env)->DeleteLocalRef(tempObj); ??
            return tempObj;
    }So is this how i do it for a function that is nativly defined as:
    public native JSources getJSourceData();?
    if this is right, then im cooking, and cannot thank you enough!
    -Shane

  • Returning arrays using JNI

    Hi all,
    Hi,
    I am in the process of accessing the MS cryptoPI using java-jni-CryptoAPI. SO far i have been able to suceesfully acessing the cryptoapi functions. There are certificate stores istalled in our windows OS called "root", "CA" and "My" .Each of these stores have a lot of certificates installed . Till now i have written a program which opens the "My" cert store. In this case, it has only one certificate whose name is stored in pszNameString. In this case, the cert name is "AMS vivek" .I dont have any problem in passing the string back to java code if there is only one certificate involved. Supposing i retireve 2 certs,whose cert names are "AMS Vivek" and "Wipro Vivek" how do i pass them back to the java application. How do i store the names of the certificate in the native code and how do i pass them back to the java code??PLease help!
    import java.awt.*;
    import java.io.*;
    import java.lang.*;
    import java.applet.*;
    public class Testapp extends Applet {
         String ret=null;
    public void init(){
              System.out.println("in init");
              loaddll();
         public void loaddll(){
                        System.out.println("before loading DLL");
                        System.loadLibrary("Msgimpl");
                        System.out.println("After loading DLL");
         private native String crypto(String store);
    public void paint(Graphics g) {
              g.setColor(Color.blue);
              g.setColor(Color.magenta);
              g.drawString("call before native function", 25, 25);
              ret=crypto("My");
         g.drawString(ret, 25, 50);
              g.drawString("Finally", 25, 75);
    #define WIN32WINNT 0x0400
    #include <windows.h>
    #include <jni.h>
    #include <wincrypt.h>
    #define MY_ENCODING_TYPE (PKCS_7_ASN_ENCODING | X509_ASN_ENCODING)
    #include "Testapp.h"
    BOOL APIENTRY DllMain(HANDLE hModule,
    DWORD dwReason, void** lpReserved) {
    return TRUE;
    JNIEXPORT jstring JNICALL
    Java_Testapp_crypto(JNIEnv * jEnv,jobject obj,jstring jstore) {
         HCRYPTPROV               hProv;
              BOOL                    bResult;
              HCERTSTORE hStoreHandle = NULL;
              PCCERT_CONTEXT          pCertContext = NULL;
              char                    pszNameString[256];
              CRYPT_KEY_PROV_INFO *pCryptKeyProvInfo;
              DWORD                    dwPropId=0;
              DWORD                    cbData;
              const char *msg;
              jstring jstr;
              msg = (*jEnv)->GetStringUTFChars(jEnv, jstore,0);
              //printf("Before context\n");
              if (hStoreHandle = CertOpenSystemStore(NULL,msg))
              printf("The %s store has been opened. \n", msg);
              else
              printf("The store was not opened.\n");
              exit(1);
         while(pCertContext= CertEnumCertificatesInStore(hStoreHandle,pCertContext))
                                       // on the first call to the function,
              // this parameter is NULL
              // on all subsequent calls,
              // this parameter is the last pointer
              // returned by the function
              if(CertGetNameString(pCertContext,CERT_NAME_FRIENDLY_DISPLAY_TYPE,0,NULL,pszNameString,1000))
              printf("\nCertificate for %s \n",pszNameString);
                   else
                   printf("\nGetNameFailed\n");
         }//main while
         return (*jEnv)->NewStringUTF(jEnv, pszNameString);
         //(*jEnv)->ReleaseStringUTFChars(jEnv, jstore,msg);
         if (!CertCloseStore(hStoreHandle,0))
         //printf("Failed CertCloseStore\n");
         exit(1);
              //printf("After context\n");

    Testapp.h is the header file that java creates.It conatins the definition of the native methods to be used.u can create a header file using
    javah -jni Testapp(class file...u must forst compile the .java file)
    * DO NOT EDIT THIS FILE - it is machine generated */
    #include <jni.h>
    /* Header for class Testapp */
    #ifndef IncludedTestapp
    #define IncludedTestapp
    #ifdef __cplusplus
    extern "C" {
    #endif
    /* Inaccessible static: LOCK */
    /* Inaccessible static: dbg */
    /* Inaccessible static: isInc */
    /* Inaccessible static: incRate */
    #undef Testapp_TOP_ALIGNMENT
    #define Testapp_TOP_ALIGNMENT 0.0f
    #undef Testapp_CENTER_ALIGNMENT
    #define Testapp_CENTER_ALIGNMENT 0.5f
    #undef Testapp_BOTTOM_ALIGNMENT
    #define Testapp_BOTTOM_ALIGNMENT 1.0f
    #undef Testapp_LEFT_ALIGNMENT
    #define Testapp_LEFT_ALIGNMENT 0.0f
    #undef Testapp_RIGHT_ALIGNMENT
    #define Testapp_RIGHT_ALIGNMENT 1.0f
    #undef Testapp_serialVersionUID
    #define Testapp_serialVersionUID -7644114512714619750LL
    /* Inaccessible static: metrics */
    /* Inaccessible static: class_00024java_00024awt_00024Component */
    /* Inaccessible static: class_00024java_00024awt_00024event_00024ComponentListener */
    /* Inaccessible static: class_00024java_00024awt_00024event_00024FocusListener */
    /* Inaccessible static: class_00024java_00024awt_00024event_00024HierarchyListener */
    /* Inaccessible static: class_00024java_00024awt_00024event_00024HierarchyBoundsListener */
    /* Inaccessible static: class_00024java_00024awt_00024event_00024KeyListener */
    /* Inaccessible static: class_00024java_00024awt_00024event_00024MouseListener */
    /* Inaccessible static: class_00024java_00024awt_00024event_00024MouseMotionListener */
    /* Inaccessible static: class_00024java_00024awt_00024event_00024InputMethodListener */
    #undef Testapp_serialVersionUID
    #define Testapp_serialVersionUID 4613797578919906343LL
    /* Inaccessible static: dbg */
    /* Inaccessible static: class_00024java_00024awt_00024Container */
    /* Inaccessible static: class_00024java_00024awt_00024event_00024ContainerListener */
    /* Inaccessible static: nameCounter */
    #undef Testapp_serialVersionUID
    #define Testapp_serialVersionUID -2728009084054400034LL
    #undef Testapp_serialVersionUID
    #define Testapp_serialVersionUID -5836846270535785031LL
    * Class: Testapp
    * Method: listCertificate
    * Signature: (Ljava/lang/String;)[Ljava/lang/String;
    JNIEXPORT jobjectArray JNICALL Java_Testapp_listCertificate
    (JNIEnv *, jobject, jstring);
    * Class: Testapp
    * Method: certificateKey
    * Signature: (Ljava/lang/String;[B)V
    JNIEXPORT void JNICALL Java_Testapp_certificateKey
    (JNIEnv *, jobject, jstring, jbyteArray);
    #ifdef __cplusplus
    #endif
    #endif

  • Problem Web Dynpro Java applications using JasperReports

    Hello all,
    We have followed the footsteps of these blogs but we can not make it work.
    Part I --> Part-I: Print Web Dynpro Java applications using JasperReports
    Part II --> Part-II: Print Web Dynpro Java applications using JasperReports
    Part III --> Part-III: Print Web Dynpro Java applications using JasperReports
    Details system: 7.02 SP3
    We believe that the problem is in the library, because it finds them.
    1) We created project as a DC external library with *.jars
    2) Public part DC external library.
    3) Add public part of DC Library into new project DC WebDynpro Java.
    4) Development Component -> Build is OK
    5) Development Component -> Deploy is OK
    6) Test app ERROR.
    When we run the application shows the error:
    The initial exception that caused the request to fail, was:
       java.lang.NoClassDefFoundError: net/sf/jasperreports/engine/JRDataSource
        at java.lang.Class.forName0(Native Method)
        at java.lang.Class.forName(Class.java:141)
        at com.unisys.tmb.View01.onActiongenerarPDF(View01.java:161)
        at com.unisys.tmb.wdp.InternalView01.wdInvokeEventHandler(InternalView01.java:140)
        at com.sap.tc.webdynpro.progmodel.generation.DelegatingView.invokeEventHandler(DelegatingView.java:87)
        ... 28 more
    See full exception chain for details.
    Regards,
    Luis.

    Hello John,
    Thanks for the link. We have performed the steps in this blog:
    1) Create DC Project "External Library" with name js/jars:
    - Add *.jars in folder Libraries.[Screenshot Libraries|http://img846.imageshack.us/img846/8395/jsjars.jpg]
    - Add archives (*.jar) to public part with name ExternalLib. Which option to choose?
    a- Provides an API for developing/compiling other DCs (Option chosen)
    b- Can be packaged into other build results (eg SDAs)
    - Development Component -&gt; Build
    Step 1 is OK.
    2) Create "J2EE Server Component / Library" DC with name js/lib:
    - Add Used DC -> public part project ExternalLibrary -> "ExternalLib"
    - Specify both build time and run-time dependency here and strong.
    - Generated SDA file in <var>gen/default/deploy</var> How do we check that it contains <var>js.jar</var>?
    - folder gen/default/plublic/defLib/lib/java then you meet *.jars files again. is OK.
    - Development Component -> Deploy.
    - Go to Visual Administrator. We found the library js/lib, but has no associated *. jar. It is the problem.[Screenshot Visual Administrator|http://img542.imageshack.us/img542/5537/visualadminlib.jpg]
    3) Create "WebDynpro" DC with name pdf_jasper
    - Add used DC (defLib) to WebDynpro DC with option "Build time".
    - WebDynpro References -> Library references --> add <var>jslib
    - Deploy
    - Run error: java.lang.NoClassDefFoundError: net/sf/jasperreports/engine/JRDataSource
    Regards,
    Luis.

  • Creating a byte Array dynamically.Urgent Help needed.

    Hi there,
    I need to create a byte Array with the values
    derived from the array and then am passing this byte array
    to a method.
    Example :
    public static void main(String[] args) throws IOException {
    char chars[] = {'a','j','a','y'};
    byte[] b = {
    (byte) chars[0],(byte) chars[1],(byte) chars[2],(byte) chars[3],
    //** Send name to a server.
    sendRequest(b);
    This is all right.
    But here I know the size of the character array chars.
    If it had more than 4 characters or less than 4,
    is there a way to create the byte array dynamically based on the values in the character array?
    Please can some one help me with creating a byte array on the fly?
    Has anyone understood my question please?
    A response is much much appreciated.

    The actual problem is this.
    The byte array already has some fixed values to it
    and i need to append the values of the character array
    to this byte array
    ie
    char chars[] = {'a','j','a','y'};
    byte b[] = {
    // Predefined values
    (byte) 0x01, (byte) 0x7E, (byte)0x03
    // I have to add the values from the array here
    (byte) chars[0], (byte) chars[1]....
    How can I add these values.? The size of the character array
    can vary

  • Trying to create a certificate file using keytool -help!

    Hi, I've followed a series of instructions using Terminal to create a certificate. Terminal produced a file and when i open it using Text Edit its about 20 lines long worth of code. I was hoping it would provide a certificate I could use. Maybe it has, I just don't know what I'm looking for!
    Im working in Viewer Builder and I'm in the Provisioning tab trying to enter the "Application ID"
    I'm totally stuck here. Please help!

    I'm using DPS pro. My app is for Android but won't be going as far as Google Play or Amazon. It's for internal use so I want to create an APK file to distribute via email. These are the set of instructions I'm following. I'm struggling to get this to work. What should I see when this has worked? Also what do I need to enter for the Application ID?
    Thanks or your help
    (Mac OS) Create a certificate file using Keytool
    Open Terminal, which is located in the Applications > Utilities folder.
    Type (or paste) the following line (replace “myname.key.p12” with the actual name of your certificate):
    1
    keytool -genkey -v -keystore myname.key.p12 -alias alias_name -keyalg RSA -keysize 2048 -storetype pkcs12 -validity 10000
    Specifying “10000” sets the expiration date after 22 October 2033.
    Enter and reenter a password. Until the Viewer Builder supports the creation of custom Android apps, it's necessary to share this password with Adobe. Create a password that you can share.
    Follow the prompts to specify the certificate information.
    When prompted to confirm choices, enter yes, and then press Return to use the same password.
    A certificate is created in your prompt location, such as your user name folder. Copy this certificate file to a known location. Write down the password as well.

  • Help creating .dll with c using JNI

    Hi. I have created a JNI application that uses C to call Java. Now, I am trying to create the .dll for windows. I am using VS C++ compiler. My program compiles; however, it doesn't seem to start the JVM. I am not sure how to pass the arguments in VS C++ while builiding and running. Please let me know. Thanks.

    Hey,
    Thanks. I apologize for not being clear. I have created the dll file and an application that links to that dll and executes the code. It creates the .exe file and when I execute it, it goes through the sample() function that just prints "Hello", and then it goes through the startJVM() function where the JVM is intended to start; however, the status of JVM is returning -1. It's not able to start JVM. I have included the path for the jvm.dll and jvm.lib. But, still won't work. Please reply with suggestions/comments. Thanks again.

  • Problem creating schema source while using WebService in MessageMapping

    Hi, scenario is RFC2WS.
    Problem that occurs is that when i want to use a method from WebService in MessageMapping XI won't import the structure. I am getting following error. The WSDL is from an external portal on which a WebService is ready to invoke.
    <b>What might be the problem?! </b>
    <i>
    Problem when creating schema source:
    Details
    java.lang.NullPointerException
    STACKTRACE:
    com.sap.aii.utilxi.misc.api.BaseException: java.lang.NullPointerException
        at com.sap.aii.ib.gui.xmleditor.docview.views.XsdSchemaTextable.setSchema(XsdSchemaTextable.java:86)
        at com.sap.aii.ib.gui.xmleditor.docview.views.XsdContainerTextView.setSchema(XsdContainerTextView.java:46)
        at com.sap.aii.ib.gui.xmleditor.docview.views.XsdContainerTextView.<init>(XsdContainerTextView.java:36)
        at com.sap.aii.ib.gui.xmleditor.docview.MultiViewEditor.makeFromTreeDoc(MultiViewEditor.java:216)
        at com.sap.aii.ib.gui.xmleditor.docview.MultiViewEditor.<init>(MultiViewEditor.java:64)
        at com.sap.aii.mappingtool.mf.TransformationPanel.createTargetView(TransformationPanel.java:264)
        at com.sap.aii.mappingtool.mf.TransformationPanel.<init>(TransformationPanel.java:100)
        at com.sap.aii.mappingtool.mf.MappingTool.<init>(MappingTool.java:32)
        at com.sap.aii.mappingtool.api.MappingToolFactory.getInstance(MappingToolFactory.java:96)
        at com.sap.aii.mappingtool.fwutil.util.ToolUtil.restartTool(ToolUtil.java:315)
        at com.sap.aii.ibrep.gui.mapping.xitrafo.XiTransformationView.loadIfrSchema(XiTransformationView.java:274)
        at com.sap.aii.ibrep.gui.mapping.xitrafo.XiMappingView$LinkDataTarget.setData(XiMappingView.java:378)
        at com.sap.aii.ibrep.gui.mapping.xitrafo.XiTransformationView$MessageDataTarget.setData(XiTransformationView.java:973)
        at com.sap.aii.utilxi.swing.toolkit.dnd.DataTarget.setData(DataTarget.java:514)
        at com.sap.aii.utilxi.swing.toolkit.dnd.DataTarget.drop(DataTarget.java:462)
        at java.awt.dnd.DropTarget.drop(Unknown Source)
        at sun.awt.dnd.SunDropTargetContextPeer.processDropMessage(Unknown Source)
        at sun.awt.dnd.SunDropTargetContextPeer.access$800(Unknown Source)
        at sun.awt.dnd.SunDropTargetContextPeer$EventDispatcher.dispatchDropEvent(Unknown Source)
        at sun.awt.dnd.SunDropTargetContextPeer$EventDispatcher.dispatchEvent(Unknown Source)
        at sun.awt.dnd.SunDropTargetEvent.dispatch(Unknown Source)
        at java.awt.Component.dispatchEventImpl(Unknown Source)
        at java.awt.Container.dispatchEventImpl(Unknown Source)
        at java.awt.Component.dispatchEvent(Unknown Source)
        at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
        at java.awt.LightweightDispatcher.processDropTargetEvent(Unknown Source)
        at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
        at java.awt.Container.dispatchEventImpl(Unknown Source)
        at java.awt.Window.dispatchEventImpl(Unknown Source)
        at java.awt.Component.dispatchEvent(Unknown Source)
        at java.awt.EventQueue.dispatchEvent(Unknown Source)
        at java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown Source)
        at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
        at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
        at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
        at java.awt.EventDispatchThread.run(Unknown Source)
    STACKTRACE:
    java.lang.NullPointerException
        at com.sap.aii.utilxi.xsd.api.XsdHandler.saveSchemaToDocument(XsdHandler.java:61)
        at com.sap.aii.ib.gui.xmleditor.docview.views.XsdSchemaTextable.setSchema(XsdSchemaTextable.java:82)
        at com.sap.aii.ib.gui.xmleditor.docview.views.XsdContainerTextView.setSchema(XsdContainerTextView.java:46)
        at com.sap.aii.ib.gui.xmleditor.docview.views.XsdContainerTextView.<init>(XsdContainerTextView.java:36)
        at com.sap.aii.ib.gui.xmleditor.docview.MultiViewEditor.makeFromTreeDoc(MultiViewEditor.java:216)
        at com.sap.aii.ib.gui.xmleditor.docview.MultiViewEditor.<init>(MultiViewEditor.java:64)
        at com.sap.aii.mappingtool.mf.TransformationPanel.createTargetView(TransformationPanel.java:264)
        at com.sap.aii.mappingtool.mf.TransformationPanel.<init>(TransformationPanel.java:100)
        at com.sap.aii.mappingtool.mf.MappingTool.<init>(MappingTool.java:32)
        at com.sap.aii.mappingtool.api.MappingToolFactory.getInstance(MappingToolFactory.java:96)
        at com.sap.aii.mappingtool.fwutil.util.ToolUtil.restartTool(ToolUtil.java:315)
        at com.sap.aii.ibrep.gui.mapping.xitrafo.XiTransformationView.loadIfrSchema(XiTransformationView.java:274)
        at com.sap.aii.ibrep.gui.mapping.xitrafo.XiMappingView$LinkDataTarget.setData(XiMappingView.java:378)
        at com.sap.aii.ibrep.gui.mapping.xitrafo.XiTransformationView$MessageDataTarget.setData(XiTransformationView.java:973)
        at com.sap.aii.utilxi.swing.toolkit.dnd.DataTarget.setData(DataTarget.java:514)
        at com.sap.aii.utilxi.swing.toolkit.dnd.DataTarget.drop(DataTarget.java:462)
        at java.awt.dnd.DropTarget.drop(Unknown Source)
        at sun.awt.dnd.SunDropTargetContextPeer.processDropMessage(Unknown Source)
        at sun.awt.dnd.SunDropTargetContextPeer.access$800(Unknown Source)
        at sun.awt.dnd.SunDropTargetContextPeer$EventDispatcher.dispatchDropEvent(Unknown Source)
        at sun.awt.dnd.SunDropTargetContextPeer$EventDispatcher.dispatchEvent(Unknown Source)
        at sun.awt.dnd.SunDropTargetEvent.dispatch(Unknown Source)
        at java.awt.Component.dispatchEventImpl(Unknown Source)
        at java.awt.Container.dispatchEventImpl(Unknown Source)
        at java.awt.Component.dispatchEvent(Unknown Source)
        at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
        at java.awt.LightweightDispatcher.processDropTargetEvent(Unknown Source)
        at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
        at java.awt.Container.dispatchEventImpl(Unknown Source)
        at java.awt.Window.dispatchEventImpl(Unknown Source)
        at java.awt.Component.dispatchEvent(Unknown Source)
        at java.awt.EventQueue.dispatchEvent(Unknown Source)
        at java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown Source)
        at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
        at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
        at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
        at java.awt.EventDispatchThread.run(Unknown Source)
    </i>

    Hi ,
    Can you please cross check these steps carefully.
    1. After importing the WSDL using external definition, did you checked msges Tab for for the included msg to see what msges you have added.
    and be careful that the namespaces of the messages are part of the WSDL description and can differ from the namespace of the external definition object.
    2.Did you created message Interface corresponding to the message types from the external definition? it is needed to route the message to webService. Here select message types of the external definition object. Assign input and output messages.
    3. Creating a SOAP Receiver Channel
    To call the Web service, you create a communication channel with type SOAP and
    direction receiver in the Integration Directory. The obligatory parameters in the
    configuration are Target URL and SOAP action. You get the values you have to enter
    here from the WSDL file.
    Creating a SOAP Sender Channel
    When you create a SOAP sender channel you have to define the namespace and the
    name of a message interface. Since no input help is provided, you copy and paste the
    values from your Integration Repository.
    Select the Quality of Service according to your interface type. If you are using a
    synchronous interface, select Best Effort. Otherwise, select Exactly Once or EOIO.
    Hope this will help you to figure out.
    Regards
    Aashish Sinha
    PS : reward points if helpful

  • Problem creating web service client using WSM Policies

    Hello everyone,
    I'm trying to make a simple java client to a Web Service secured using a WSM 11gR1 policy (from Soa Suite 11.1.1.2.0). The policy on the server side is oracle/wss11_x509_token_with_message_protection_service_policy which I attached via the Weblogic Admin Console. To implement the client I'm trying to follow the instructions from this documentation: http://download.oracle.com/docs/cd/E15523_01/web.1111/e13713/owsm_appendix.htm#WSSOV386 section "Policy Configuration Overrides for the Web Service Client" and also I'm using OEPE 11.1.1.3.0 (Eclipse 3.5.0) to develop the client. The only weblogic jar I've added to the build path is the weblogic.jar . Unfortunately, the oracle.wsm.security.util.SecurityConstants.ClientConstants interface (used in the example A-6) is not included in this jar and I have no idea what other libraries should I include in order to follow the example. I tried manualy adding other jars but without success. In fact I found one jar which includes this interface, the wsm-secpol.jar but it does not have the properties described in the documentation, so I guess it's not the right jar, and also I don't think this is the right procedure since there might be another dependent jars. So I would like to know what libraries exactly I should add to the build path (or some other procedure if you noticed I'm doing anything wrong)
    Thank you !

    Hi
    I am having the same problem almost where i wrote a client to comsume a JWS server in https. Where the server is setup to require a certificate to connect to.
    My code:
    public static void main(String[] args) {
    try {
    DataBaseSyncServerImpl port = new DataBaseSyncServerImplService().getDataBaseSyncServerImplPort();
    int number1 = 20;
    int number2 = 10;
    System.out.printf("Invoking divide method(%d, %d)\n", number1, number2);
    double result = port.divide(number1, number2);
    System.out.printf("The result of dividing %d and %d is %f.\n\n", number1, number2, result);
    when run this code throw
    run:
    [java] Invoking divide method(20, 10)
    [java] Exception in thread "main" javax.xml.ws.WebServiceException: HTTP transport error: javax.net.ssl.SSLHandshak
    eException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCert
    PathBuilderException: unable to find valid certification path to requested target
    Does any one know how can I solve this problem or how can I make the client be able to use self signed certificates. Any help is greatly apprecited. Thanks

  • Problems creating notation from scratch using the edit function of GarageBa

    I am using garage band to write music. I open
    a blank loop with a grand piano system instrument and
    begin editing. I encounter the following problems:
    1. The software does not allow me to enter any note
    below middle c on additional or ledger lines that
    should be available below the stave of the treble
    clef.
    1.1 Connected to this issue is that it is very
    difficult to write music that contains subtleties.
    This directly affects the way the music sounds. The
    program substitutes accidentals in the stave
    conditioned by the key signature. For example writing
    Chopin in GarageBand as opposed to the written sheet
    music is the difference between buying a designer
    dress in a Bond Street Boutique and buying a cheap
    copy in Primark. "Brins Bungalo" Tutorial claims
    that
    Garageband "is an application suitable for both the
    dabbler and the conservatorially trained."
    2. When there are many notes to be entered in a bar
    garageBand is not flexible to accomodate the notes
    required, Notes are clustered in a bunch makiing it
    difficult to read what has been written (preventing the composer checking that it has been written correctly).
    3. When there are many notes to be written in a bar
    e.g. more than, say four notes, (lots of quavers or semi quavers) the
    program does some strange things which I am unable to
    control:
    a) groups unrelated larger notes with the smaller
    notes and will not allow them to be separated;
    b) changes the value of notes already entered;
    c) sometimes splits the note being entered into two
    smaller notes joined by a tie;
    d) accidentals appear on notes entered or notes
    already entered without my instruction;
    e) it changes note values, filling up the bar, to the
    value of the time key before I have a chance to finish
    entering the remaining notes that I want to place in
    the bar;
    4. How is one able to enter "dynamics" (symbol marks
    of expression). I know it is possible because many of
    the preloaded loops have these expressions evident
    within them. I have tried consulting GarageBand Help but this has proved impossible to fathom.
    Can anyone help?
    iMac   Mac OS X (10.4.8)  

    You have my sympathy as I also wanted to enter notes on a stave but GB is simply not designed to do it.
    You can do an amazing amount with GB but complex scoring is not really possible. You can't print a score btw.
    In answer to some of your questions,
    Expression cannot be added using the scoring facility. You need to go back to the piano roll view and use the expression/modulation/pitchbend/footswitch parameters.
    I think you're possibly doing something wrong as I've just done a little test and I've entered a C0 without a problem.
    I've also not had problems moving notes about and getting the right length or having GB fill notes to the end of the bar.
    This is how I do it.
    Create a software track.
    Double click on the track to get the track editor.
    Press record and use the the keyboard on the piano roll to enter a note. You've now created a recording region. You can't enter notes outside a recording region so you might need to drag it out to the required size.
    Swap to note entry. That gives you the double stave. Drag the grey bar that separates the arranger area from the track editor upwards. This gives you more space on the stave.
    Command click anywhere on the stave and a note will appear. Just move that note to wherever you want it and click to set it in place. You can always move it again by left clicking on the note and dragging it.
    Accidentals will depend on the key you've set for the song and what notes you're entering. In D for instance you won't get an accidental for F sharp but you will get one for A flat.
    Let us know how you get on.
    If this still doesn't give you what you need then I suggest a dedicated notation package. Create a midi file from the package and import into GB for final tweaking.
    Cheers
    Dick

  • Creating an interactive map, using buttons, help!?

    Hi,
    I am attempting to create an interactive map of the college I work at.  I have created a button and when you click on the area, it displays info about the particular room or subject.
    I am using Oject States for the room/subject info and when you press the button to select it, when the room info is displayed (as it should), but the button appears on the top of it.
    I would also like to have a back/close button to go back the the original map.
    Please help, I am new to this and would appreciate any help.
    Thanks

    To Bob Bringhurst,
    Maybe you could show your workaround as a step by step approach
    http://blogs.adobe.com/indesigndocs/2010/12/hot-spot-button-workaround -for-indesign-dig-pubs.html
    Having also viewed this video on creating a tooltip.
    Im still having problems after viewing the above video's to get Multi State Objects viewing correctly on the iPad.
    This might resolve a problem for myself, and possibly others.
    Regards
    Vividi

  • How to run an application i created in java without using eclipse

    Im familiar with running an application i create thru command prompt or eclipse, how do i create a file to run on any computer with java so i can double click the file and my application runs. C# automatically does this, do i need to do an extra step to the jar file?

    Hi,
    You need to make an executable JAR file. There are a few ways you can do this but since you are using Eclipse you can follow this tutorial.
    [http://www.fsl.cs.sunysb.edu/~dquigley/cse219/index.php?it=eclipse&tt=jar&pf=y]
    The most important part is the manifest file, if you have dependencies on other JAR files they will need to be specified along with the
    main method to call to start you program. You can do this via the Eclipse Wizard.
    It will be in your interests to read this tutorial also
    [http://java.sun.com/docs/books/tutorial/deployment/jar/]

Maybe you are looking for

  • How do I install Tiger on an external HD?

    Can I install Tiger on an external HD connected via FW from the laptop to which it's connected? It seems like the installation disk wants to restart the laptop and only install it there. How do I do a fresh install of OSX on this external HD?

  • Queries with variable input giving error

    Hello all, I have a query which asks for fiscal year and posting period at the start of query run. But when I run the query in Bex analyzer, it gives me this error all the time. "Program error in class SAPMSSY1 method : UNCAUGHT_EXCEPTION System erro

  • Down payemt restriction for some vendors

    The issue is like this Down payment to some vendors to be restricted but not through the separate vendor account group because after some point of time my client may allow them (vendor) for down payment. Thanks in Advance

  • Email configuration question

    Hi- I'm having a problem configuring my email accounts for my iPhone. I currently use an Exchange email account through school, linked to Outlook 2007 on my computer (PC). I also have a couple of Gmail and Yahoo accounts that I like to download to my

  • BPC 7.5NW consolidation error

    Hi, We are using BPC 7.5 NW version (7.50.04). We changed standard dimension 'GROUPS' to dimension type 'R' and included it in our legal applications. We are using below logic to run both currency conversion and legal consolidation. *RUN_PROGRAM CURR