Auf Thema antworten

Jetzt sieht meine Klasse so aus:

[code=Java]package soap;


import org.apache.axis.client.Call; 

import org.apache.axis.client.Service;

import javax.xml.namespace.QName;

import javax.xml.rpc.ParameterMode;

import org.apache.axis.Constants;


public class ClientTest {

    public static void main(String[] args)

          {

              try

             {       

                 String endpoint = "http://localhost:3773/soap/IIPSVariableManager";

                 Service service = new Service();

                 Call call = (Call) service.createCall();

                 call.setTargetEndpointAddress( new java.net.URL(endpoint) );

                 call.setOperationName("GetVariableID");

                 call.addParameter("VariableName", Constants.XSD_ANY , ParameterMode.IN);

                 call.addParameter("VariableID", Constants.XSD_UNSIGNEDSHORT , ParameterMode.OUT);

                 call.setReturnType(Constants.XSD_UNSIGNEDSHORT);

               

                 String result = call.invoke(new Object[]{"input0"}).toString();    // VariableName = "input0"

                 System.out.println(result);    

             }

             catch (Exception e)

             {

                System.err.println(e.toString());

                e.printStackTrace();

             }

             System.exit(0);

         }

}

[/code]


Und die Fehlermeldung ist :

[code=Java]Variable mit Namen "" existiert nicht

AxisFault

......[/code]


Denke ich in die falsche Richtung mit addParameter?

Ich muss irgendwie Parameter in GetVariableID einpacken...



Oben