Hi,
I am trying to access .net web service from jave
(sun one studio)
and i get an error msg.
this is the code:
import org.apache.soap.util.xml.*;
import org.apache.soap.*;
import org.apache.soap.rpc.*;
import java.net.URL;
import java.util.*;
import java.net.URL;
public class MyClient
{
public static void main(String args) throws Exception
{
java.net.URL url = new
java.net.URL(" bgu.ac.il/webservices/user_auth henticate/authenticate.asmx);
Call call = new Call ();
call.setEncodingStyleURI(Constants.NS_URI_SOAP_ENC);
//namespace
call.setTargetObjectURI (" bservices");
call.setMethodName ("checkUser");
Vector params = new Vector ();
params.addElement (new Parameter("txtUsername", String.class, "username" , null));
params.addElement (new Parameter("txtPassword", String.class, "password" , null));
call.setParams (params);
Response resp = call.invoke (url, " services/checkUser");
Parameter ret = resp.getReturnValue();
String retResult = (String)ret.getValue();
System.out.println("Success, result: " + retResult);
}
}
and i am getting the error:
SOAPException fault code: SOAP-ENV:Client message: No Deserializer found to deserialize a ' using encoding style 'null'.
can someone help me please?
thank you.
I am trying to access .net web service from jave
(sun one studio)
and i get an error msg.
this is the code:
import org.apache.soap.util.xml.*;
import org.apache.soap.*;
import org.apache.soap.rpc.*;
import java.net.URL;
import java.util.*;
import java.net.URL;
public class MyClient
{
public static void main(String args) throws Exception
{
java.net.URL url = new
java.net.URL(" bgu.ac.il/webservices/user_auth henticate/authenticate.asmx);
Call call = new Call ();
call.setEncodingStyleURI(Constants.NS_URI_SOAP_ENC);
//namespace
call.setTargetObjectURI (" bservices");
call.setMethodName ("checkUser");
Vector params = new Vector ();
params.addElement (new Parameter("txtUsername", String.class, "username" , null));
params.addElement (new Parameter("txtPassword", String.class, "password" , null));
call.setParams (params);
Response resp = call.invoke (url, " services/checkUser");
Parameter ret = resp.getReturnValue();
String retResult = (String)ret.getValue();
System.out.println("Success, result: " + retResult);
}
}
and i am getting the error:
SOAPException fault code: SOAP-ENV:Client message: No Deserializer found to deserialize a ' using encoding style 'null'.
can someone help me please?
thank you.