Invoke JCAPS webservice from Java Application

I am getting
AxisFault
faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Client
faultSubcode:
faultString: JAXRPC.TIE.01: caught exception while handling request: unrecognized operation: Test
faultActor:
faultNode:
faultDetail:
{http://xml.apache.org/axis/}stackTrace: AxisFault
faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Client
faultSubcode:
faultString: JAXRPC.TIE.01: caught exception while handling request: unrecognized operation: Test
faultActor:
faultNode:
faultDetail:
JAXRPC.TIE.01: caught exception while handling request: unrecognized operation: Test
at org.apache.axis.message.SOAPFaultBuilder.createFault(SOAPFaultBuilder.java:260)
at org.apache.axis.message.SOAPFaultBuilder.endElement(SOAPFaultBuilder.java:169)
at org.apache.axis.encoding.DeserializationContextImpl.endElement(DeserializationContextImpl. java:1015)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endElement(AbstractSAXParser. java:633)
at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanEndElement(XMLNSDocum entScannerImpl.java:719)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDisp atcher.dispatch(XMLDocumentFragmentScannerImpl.java:1685)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDoc umentFragmentScannerImpl.java:368)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.jav a:834)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.jav a:764)
at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:148)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java: 1242)
at javax.xml.parsers.SAXParser.parse(SAXParser.java:375)
==========================================================
JAVA CODE :
public static void main(String[] args) {
// TODO code application logic here
try {
WebServiceClient wsClient = new WebServiceClient();
String strTargetNameSpaceIn ="urn:stc:egate:jce roject3_Collaboration_1" ;
String strPortNameIn = "ExecutePortType";
String strServiceNameIn ="Project3_Collaboration_1Service" ;
String strOperationNameIn ="Test" ;
//String strWebserviceURLIn = "http://165.68.202.246:8080/uddidocs/Nonesecurewebservice/testweb3/jc/wsdl_jce_jc-2145777518.wsdl";
String strWebserviceURLIn = "http://localhost:8080/uddidocs/EnvUCHDevLocal/Project3/Collaboration_1/wsdl_jce_Collaboration_1771627736.wsdl ";
String strInputIn = " Test JCAPS WebService ";
String output = wsClient.callWebService(strTargetNameSpaceIn,strPortNameIn,strServiceNameIn,strOperationNa meIn,strWebserviceURLIn,strInputIn);
System.out.println("WebService Output " + output);
} catch (Exception err) {
System.out.println( " EXCEPTION OCCURED");
err.printStackTrace();
public String callWebService(String strTargetNameSpace,String strPortName,String strServiceName,String strOperationName,String strWebserviceURL,String strInput) throws ServiceException, MalformedURLException, RemoteException
if(strTargetNameSpace==null || strPortName == null || strServiceName == null || strOperationName == null || strWebserviceURL ==null || strInput == null )
throw new IllegalArgumentException();
ServiceFactory factory = ServiceFactory.newInstance();
// for webservice target namespace
String targetNamespace =strTargetNameSpace;
// for webservice name
QName serviceName = new QName(strTargetNameSpace,strServiceName);
// for webservice port name
QName portName = new QName(strTargetNameSpace,strPortName);
// for operation name
QName operationName = new QName("urn:stc:egate:jce roject3:Collaboration_1WSDL:Test",strOperationName);
// for url of webservice ".wsdl" file
URL wsdlLocation = new URL(strWebserviceURL);
if(wsdlLocation==null)
throw new ServiceException();
// for bind to service name with wsdl file
Service service = factory.createService(wsdlLocation, serviceName);
// for call to webservice using operation name
Call call = service.createCall(portName, operationName);
String result = null;
try{
System.out.println(" STR INPUT" + strInput);
result = (String) call.invoke(new Object[] {strInput});
}catch(Exception e){
e.printStackTrace();
result="Occur webservice processing error";
if(result==null)
result="Occur webservice processing error";
String str = "Webservice Responce from :"+strWebserviceURL;
return result;
}//close function
=========================================================
WSDL FILE :
<?xml version="1.0" encoding="UTF-8"?>
<definitions name="Project3_Collaboration_1" targetNamespace="urn:stc:egate:jce roject3_Collaboration_1" xmlns:tns="urn:stc:egate:jce roject3_Collaboration_1" xmlns:inMsg="http://dn1318d-uwsxp:13000/repository/UCHDevLocal/Project3/UCHDevLocal23b1e1:1192e3ad66a:-8000/XSDDefinition1" xmlns:errMsg="urn:stc:egate:jce:JavaException" xmlnsutMsg="http://dn1318d-uwsxp:13000/repository/UCHDevLocal/Project3/UCHDevLocal23b1e1:1192e3ad66a:-7fff/XSDDefinition2" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns="http://schemas.xmlsoap.org/wsdl/">
<import namespace="http://dn1318d-uwsxp:13000/repository/UCHDevLocal/Project3/UCHDevLocal23b1e1:1192e3ad66a:-7fff/XSDDefinition2" location="XSDDefinition2.xsd"/>
<import namespace="http://dn1318d-uwsxp:13000/repository/UCHDevLocal/Project3/UCHDevLocal23b1e1:1192e3ad66a:-8000/XSDDefinition1" location="XSDDefinition1.xsd"/>
<types>
<xs:schema elementFormDefault="qualified" id="UID-20000000-DC88392E190100-A544977D-01" targetNamespace="urn:stc:egate:jce:JavaException" xmlns="urn:stc:egate:jce:JavaException" xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:element name="JavaException" type="JavaExceptionType"/>
<xs:complexType name="JavaExceptionType">
<xs:sequence>
<xs:element name="Type" type="xs:string"/>
<xs:element name="Message" type="xs:string"/>
<xs:element name="Trace" type="xs:string"/>
</xs:sequence>
</xs:complexType>
</xs:schema>
</types>
<message name="Output">
<part name="Body" element="outMsg utput"/>
</message>
<message name="Input">
<part name="Body" element="inMsg:Input"/>
</message>
<message name="JavaExceptionMessage">
<part name="FaultDetails" element="errMsg:JavaException"/>
</message>
<portType name="ExecutePortType">
<operation name="Test">
<input name="Input" message="tns:Input"/>
<output name="Output" message="tns utput"/>
<fault name="JavaException" message="tns:JavaExceptionMessage"/>
</operation>
</portType>
<binding name="ExecutePortTypeBinding" type="tns:ExecutePortType">
<soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
<operation name="Test">
<soapperation soapAction="urn:stc:egate:jce roject3:Collaboration_1WSDL:Test" style="document"/>
<input name="Input">
<soap:body parts="Body" use="literal" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
</input>
<output name="Output">
<soap:body parts="Body" use="literal" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
</output>
<fault name="JavaException">
<soap:fault name="JavaException" use="literal" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
</fault>
</operation>
</binding>
<service name="Project3_Collaboration_1Service">
<port name="ExecutePortType" binding="tns:ExecutePortTypeBinding">
<soap:address location="http://localhost:18501/WsServer/ExecutePortType"/>
</port>
</service>
</definitions>

Hi Abinap.
If you are woking with JEE 1.3 or JAX-RPC.
You need to add some libraries to java project.
Go to the tab "Add Libraries" on context menu of the project: Properties --> Java build Path
Select "Add variable" button, after select the SAP_WEBSERVICES_EXT_LIBS_HOME variable and click on "Extend" Button, finally select all the libraries under lib folder, do the same to the SAP_XML_TOOLKIT_LIBS_HOME variable.
Greetings.
Manuel Loayza Gahona

Similar Messages

  • How to call webservice from Java application

    Hi XI gurus
    Pls let me know how to call a webservice from Java application.
    I wanted to build synchronous interface from Java Application to SAP using SAP XI
    For example, i need to create Material master from Java application and the return message from SAP, should be seen in Java application
    Regards
    MD

    Hi,
    If your  JAVA Application is Web based application, you can expose it as Webservice.
    JAVA People will pick the data from Dbase using their application and will send the data to XI by using our XI Details like Message Interface and Data type structure and all.
    So we can Use SOAP Adapter or HTTP in XI..
    If you use HTTP for sending the data to XI means there is no need of Adapter also. why because HTTP sits on ABAP Stack and can directly communicate with the XI Integration Server Directly
    If you are dealing with the Webservice and SAP Applications means check this
    Walkthrough - SOAP  XI  RFC/BAPI
    REgards
    Seshagiri

  • Problems to invoke java.exe from Java application, but ok for javac.exe??

    How to invoke DOS application from Java application??
    I try the following but it didn't work to invoke command prompt and java.exe, it
    is working to invoke javac.exe. Any ideas why??
    import java.io.*;
    public class CallJavaTest
    { public static void main(String[] args)
    { try
    Runtime.getRuntime().exec("C:\\WINNT\\System32\\cmd.exe"); //doesn't work!!
    Runtime.getRuntime().exec("javac "+ "Test.java"); //it works!!
    Runtime.getRuntime().exec("java "+ "Test"); //doesn't work!!
    catch(IOException e)
    System.out.println(e);

    hi
    String[] cmd = {"cmd","/c", "start",enteryourdoscommandhere};
    Runtime rt = Runtime.getRuntime();
    Process ps = rt.exec(cmd);
    ps.waitFor();
    int ev = ps.exitValue();
    it works for my winXP.
    hope it can helps and not too late ..

  • Invoking a webservice from Oracle ODI 11.1

    Hello there, new to this forum but I am having trouble invoking a webservice from a package within ODI. The error message I am recieving is as follows.
    com.sunopsis.wsinvocation.SnpsWSInvocationException: javax.xml.ws.WebServiceException: java.lang.ExceptionInInitializerError
         at oracle.odi.wsinvocation.client.impl.jaxws.OdiJaxwsClientImpl.requestReply(OdiJaxwsClientImpl.java:73)
         at oracle.odi.wsinvocation.client.impl.jaxws.OdiJaxwsOracleClientImpl.requestReply(OdiJaxwsOracleClientImpl.java:44)
         at com.sunopsis.graphical.wsclient.RequestWsPane$11$1.doInBackground(RequestWsPane.java:1235)
         at com.sunopsis.graphical.tools.utils.swingworker.SwingWorker$1.call(SwingWorker.java:240)
         at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
         at java.util.concurrent.FutureTask.run(FutureTask.java:139)
         at com.sunopsis.graphical.tools.utils.swingworker.SwingWorker.run(SwingWorker.java:279)
         at oracle.ide.dialogs.ProgressBar.run(ProgressBar.java:656)
         at java.lang.Thread.run(Thread.java:662)
    Caused by: javax.xml.ws.WebServiceException: java.lang.ExceptionInInitializerError
         at com.sun.xml.internal.ws.client.dispatch.DispatchImpl.doInvoke(DispatchImpl.java:188)
         at com.sun.xml.internal.ws.client.dispatch.DispatchImpl.invoke(DispatchImpl.java:195)
         at oracle.odi.wsinvocation.client.impl.jaxws.OdiJaxwsClientImpl.requestReply(OdiJaxwsClientImpl.java:66)
         at oracle.odi.wsinvocation.client.impl.jaxws.OdiJaxwsOracleClientImpl.requestReply(OdiJaxwsOracleClientImpl.java:44)
         at com.sunopsis.graphical.wsclient.RequestWsPane$11$1.doInBackground(RequestWsPane.java:1237)
         ... 6 more
    Caused by: java.lang.ExceptionInInitializerError
         at com.sun.xml.internal.ws.client.dispatch.DispatchImpl.doInvoke(DispatchImpl.java:173)
         at com.sun.xml.internal.ws.client.dispatch.DispatchImpl.invoke(DispatchImpl.java:195)
         at oracle.odi.wsinvocation.client.impl.jaxws.OdiJaxwsClientImpl.requestReply(OdiJaxwsClientImpl.java:66)
         at oracle.odi.wsinvocation.client.impl.jaxws.OdiJaxwsOracleClientImpl.requestReply(OdiJaxwsOracleClientImpl.java:44)
         at com.sunopsis.graphical.wsclient.RequestWsPane$11$1.doInBackground(RequestWsPane.java:1235)
         at com.sunopsis.graphical.tools.utils.swingworker.SwingWorker$1.call(SwingWorker.java:240)
         at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
         at java.util.concurrent.FutureTask.run(FutureTask.java:138)
         at com.sunopsis.graphical.tools.utils.swingworker.SwingWorker.run(SwingWorker.java:278)
         at oracle.ide.dialogs.ProgressBar.run(ProgressBar.java:655)
         ... 1 more
    Caused by: java.lang.ClassCastException: com.sun.xml.bind.v2.runtime.JAXBContextImpl
         at com.sun.xml.internal.ws.fault.SOAPFaultBuilder.<clinit>(SOAPFaultBuilder.java:533)
         at com.sun.xml.internal.ws.client.dispatch.DispatchImpl.doInvoke(DispatchImpl.java:173)
         at com.sun.xml.internal.ws.client.dispatch.DispatchImpl.invoke(DispatchImpl.java:195)
         at oracle.odi.wsinvocation.client.impl.jaxws.OdiJaxwsClientImpl.requestReply(OdiJaxwsClientImpl.java:66)
         at oracle.odi.wsinvocation.client.impl.jaxws.OdiJaxwsOracleClientImpl.requestReply(OdiJaxwsOracleClientImpl.java:44)
         at com.sunopsis.graphical.wsclient.RequestWsPane$11$1.doInBackground(RequestWsPane.java:1237)
         at com.sunopsis.graphical.tools.utils.swingworker.SwingWorker$1.call(SwingWorker.java:240)
         at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
         at java.util.concurrent.FutureTask.run(FutureTask.java:139)
         at com.sunopsis.graphical.tools.utils.swingworker.SwingWorker.run(SwingWorker.java:279)
         at oracle.ide.dialogs.ProgressBar.run(ProgressBar.java:656)
         ... 1 more
    Eventually, I would like to query a documentum DB but I can't get a simple webservice call to work correctly. Any help will greatly be appreciated.

    This forum is about Oracle Database. not about Oracle Data Integrator.
    Kindly post in the correct forum https://forums.oracle.com/forumID=374
    Sybrand Bakker
    Senior Oracle DBA

  • Calling secured webservice from java

    Hi Experts,
    I am trying to call a secured webservice from java.
    I got the code to call a non secured web service in java.
    What changes do i need to do in this to call a secured webservice.
    Please help me.
    Thank you
    Regards
    Gayaz
    calling unsecured webservice
    package wscall1;
    import java.io.BufferedReader;
    import java.io.ByteArrayOutputStream;
    import java.io.IOException;
    import java.io.InputStream;
    import java.io.InputStreamReader;
    import java.io.OutputStream;
    import java.io.StringBufferInputStream;
    import java.io.StringReader;
    import java.io.StringWriter;
    import java.io.Writer;
    import java.net.HttpURLConnection;
    import java.net.MalformedURLException;
    import java.net.URL;
    import java.net.URLConnection;
    import java.security.Permission;
    import javax.xml.parsers.DocumentBuilderFactory;
    import javax.xml.parsers.DocumentBuilder;
    import javax.xml.parsers.ParserConfigurationException;
    import org.apache.xml.serialize.OutputFormat;
    import org.apache.xml.serialize.XMLSerializer;
    import org.w3c.css.sac.InputSource;
    import org.w3c.dom.Document;
    import org.w3c.dom.NodeList;
    import org.xml.sax.SAXException;
    public class WSCall2 {
    public WSCall2() {
    super();
    public static void main(String[] args) {
    try {
    WSCall2 ss = new WSCall2();
    System.out.println(ss.getWeather("Atlanta"));
    } catch (Exception e) {
    e.printStackTrace();
    public String getWeather(String city) throws MalformedURLException, IOException {
    //Code to make a webservice HTTP request
    String responseString = "";
    String outputString = "";
    String wsURL = "https://ewm52rdv:25100/Saws/SawsService";
    URL url = new URL(wsURL);
    URLConnection connection = url.openConnection();
    HttpURLConnection httpConn = (HttpURLConnection)connection;
    ByteArrayOutputStream bout = new ByteArrayOutputStream();
    //Permission p= httpConn.getPermission();
    String xmlInput =
    "<soapenv:Envelope xmlns:soapenv=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:ser=\"http://www.ventyx.com/ServiceSuite\">\n" +
    " <soapenv:Header>\n" +
    "     <soapenv:Security>\n" +
    " <soapenv:UsernameToken>\n" +
    " <soapenv:Username>sawsuser</soapenv:Username>\n" +
    " <soapenv:Password>sawsuser1</soapenv:Password>\n" +
    " </soapenv:UsernameToken>\n" +
    " </soapenv:Security>" + "</soapenv:Header>" + " <soapenv:Body>\n" +
    " <ser:GetUser>\n" +
    " <request><![CDATA[<?xml version=\"1.0\" encoding=\"UTF-8\"?> \n" +
                "                        <GetUser xmlns=\"http://www.ventyx.com/ServiceSuite\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\">\n" +
                "                        <UserId>rs24363t</UserId>\n" +
                "                        </GetUser>]]>\n" +
    " </request>\n" +
    " </ser:GetUser>\n" +
    " </soapenv:Body>\n" +
    "</soapenv:Envelope>";
    byte[] buffer = new byte[xmlInput.length()];
    buffer = xmlInput.getBytes();
    bout.write(buffer);
    byte[] b = bout.toByteArray();
    String SOAPAction = "GetUser";
    // Set the appropriate HTTP parameters.
    httpConn.setRequestProperty("Content-Length", String.valueOf(b.length));
    httpConn.setRequestProperty("Content-Type", "text/xml; charset=utf-8");
    httpConn.setRequestProperty("SOAPAction", SOAPAction);
    // System.out.println( "opening service for [" + httpConn.getURL() + "]" );
    httpConn.setRequestMethod("POST");
    httpConn.setDoOutput(true);
    httpConn.setDoInput(true);
    OutputStream out = httpConn.getOutputStream();
    //Write the content of the request to the outputstream of the HTTP Connection.
    out.write(b);
    out.close();
    //Ready with sending the request.
    //Read the response.
    InputStreamReader isr = new InputStreamReader(httpConn.getInputStream());
    BufferedReader in = new BufferedReader(isr);
    //Write the SOAP message response to a String.
    while ((responseString = in.readLine()) != null) {
    outputString = outputString + responseString;
    //Parse the String output to a org.w3c.dom.Document and be able to reach every node with the org.w3c.dom API.
    Document document = parseXmlFile(outputString);
    NodeList nodeLst = document.getElementsByTagName("User");
    String weatherResult = nodeLst.item(0).getTextContent();
    System.out.println("Weather: " + weatherResult);
    //Write the SOAP message formatted to the console.
    String formattedSOAPResponse = formatXML(outputString);
    System.out.println(formattedSOAPResponse);
    return weatherResult;
    public String formatXML(String unformattedXml) {
    try {
    Document document = parseXmlFile(unformattedXml);
    OutputFormat format = new OutputFormat(document);
    format.setIndenting(true);
    format.setIndent(3);
    format.setOmitXMLDeclaration(true);
    Writer out = new StringWriter();
    XMLSerializer serializer = new XMLSerializer(out, format);
    serializer.serialize(document);
    return out.toString();
    } catch (IOException e) {
    throw new RuntimeException(e);
    private Document parseXmlFile(String in) {
    try {
    DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance();
    DocumentBuilder db = dbf.newDocumentBuilder();
    InputSource is = new InputSource(new StringReader(in));
    InputStream ins = new StringBufferInputStream(in);
    return db.parse(ins);
    } catch (ParserConfigurationException e) {
    throw new RuntimeException(e);
    } catch (SAXException e) {
    throw new RuntimeException(e);
    } catch (IOException e) {
    throw new RuntimeException(e);
    } catch (Exception e) {
    throw new RuntimeException(e);
    static {
    javax.net.ssl.HttpsURLConnection.setDefaultHostnameVerifier(new javax.net.ssl.HostnameVerifier() {
    public boolean verify(String hostname, javax.net.ssl.SSLSession sslSession) {
    if (hostname.equals("ewm52rdv")) {
    return true;
    return false;
    }

    Gayaz  wrote:
    What we are trying is we are invoking webservice by passing SOAP request and we will get soap response back.I understand what you're trying to do, the problem is with tools you're using it will take a while for you do anything a little away from the trivial... Using string concatenation and URL connection and HTTP post to call webservices is like to use a hand drill... It may work well to go through soft wood, but it will take a lot of effort against a concrete wall...
    JAX-WS and JAXB and annotations will do everything for you in a couple of lines and IMHO you will take longer to figure out how to do everything by hand than to learn those technologies... they are standard java, no need to add any additional jars...
    That's my thought, hope it helps...
    Cheers,
    Vlad

  • Calling SAP Webservice from JAVA ME bad response time

    Hello together,
    I'm calling a SAP RFC as a Webservice from JAVA ME (Netbeans 6.8). The stub classes I've generated with the Sun Wireless Toolkit. The RFC function stores entries in a SAP database table. The call of the websevice with transmitting the data and the database update in SAP works fine, but I got the response message from SAP with a delay of 40 seconds.
    Does anyone know why there is so a long delay in the response and how to fix it?

    hi,
    is this reproducible or was it just the first call to that service?
    it usually occurs that once you call a webservice for the first time, some of the programs (be it your application programs or the even the SOAP runtime itself) required have not been compiled until that and so they are compiled during the webservice call.
    This leads to slow response times even time-outs. The effect vanishes once all sources are compiled (i.e. depending on the complexity of your calls after one to a few calls to that service).
    So, if the slow response times persist, you should turn on debugging in SICF and see where time is spent...
    my 2 cents,
    anton

  • Invoke beanshell methods from java

    Hello
    I'm learning beanshell and using it to write scripts that are ran in JDK 6.
    My question is how to invok beanshell methods from java source codes.
    My codes is:
    import javax.script.*;
    public class InvokeFunctions {
    public static void main (String[] args)throws ScriptException, NoSuchMethodException
    ScriptEngineManager sem = new ScriptEngineManager();
    ScriptEngine bshEngine = sem.getEngineByName("beanshell");
    String script = "public void sayHello()"+"{print (\"sayHello() is a method in bsh script\");}";
    bshEngine.eval(script);
    Invocable inbshEngine = (Invocable)bshEngine;
    inbshEngine.invokeFunction("sayHello");
    I defined a method "sayHello()" using beanshell, but i just can't invoke it in Java.
    I got an error msg said:
    Exception in thread "main" java.lang.IllegalAccessError: tried to access method bsh.NameSpace.getThis(Lbsh/Interpreter;)Lbsh/This; from class bsh.engine.BshScriptEngine
    Any one has any idea about it?
    Thanks

    Look at the Javadoc documentation of IllegalAccessError. It says:
    Thrown if an application attempts to access or modify a field, or to call a method that it does not have access to.
    Normally, this error is caught by the compiler; this error can only occur at run time if the definition of a class has incompatibly changed.
    Maybe recompiling all your sources (make sure you delete all existing *.class files) will help?

  • Storing chinese in client odb from java application

    Hi all,
    first i like to thank Greg Rekounas for his wonderful support and contribution....
    This is my server setup.
    os-windows 2000 sp4
    db-oracle 9ir2 (unicode with AL32UTF8 charset)
    lite-oracle10g r2 (with latest patchset)
    nls_lang- AMERICAN_AMERICA.AL32UTF8
    storing and retriving chinese in oracle 9i database from isql*plus works.
    lite configuration.
    1. In $OLITE_HOME\mobile_oc4j\j2ee\mobileserver\applications
    \mobileserver\setup\common\webtogo\webtogo.ora file edited the JAVA_OPTION
    to:
    JAVA_OPTION=-Djava.compiler=NONE -Dfile.encoding=UTF8
    2. In $OLITE_HOME\mobile_oc4j\j2ee\mobileserver\applications
    \mobileserver\setup\dmc\common\win32.inf file, added the following:
    a. In the <file> section, added the following:
    <item>
    <src>/common/win32/olilUTF8.dll</src>
    <des>$APP_DIR$\bin\olilUTF8.dll</des>
    </item>
    b. In the <ini> section, added the following:
    <item name='POLITE.INI' section='All Databases'>
    <item name="DB_CHAR_ENCODING">UTF8</item>
    </item>
    <item name='POLITE.INI' section='SYNC'>
    <item name="DB_ENCODING">UTF8</item>
    </item>
    published the application developed in java using packaging wizard.
    downloaded the client in the pc with the following config:
    windows 2000 (english)
    nls - default.
    installed chinese language support.
    tried to access 9i database from isql*plus and stored & viewed chinese characters sucessfully.
    tried to store a chinese character from java application in the client odb -- failed.
    values are getting inserted from the application but when i view them back it shows & # 2 6 0 8 5 ; (i have included a space in between all 8 characters.
    but when i copy this no and paste in msword it shows 日(chinese character)
    i dont know the exact reason for the above scenerio...................
    Also please help me on this too.......
    why can i store & view chinese characters sucessfully in isql*plus from the client machine while i cannot do the same on client odb from java application even though the lite config are done to support utf8?
    is anything i left out?
    should i do any codes changes in java?(java application is of verision jdk1.4_13)
    Thanks,
    Ashok kumar.G

    Sorry for late replay!! in the SharePoint server both the Claim based and Classic mode is enabled in the server, but still I want to get authenticated via Classic mode just like it happens in SharePoint  2007 and 2010, so do i have to use a different
    set of classes to do that if yes can you please tell me those ?

  • Webservices in java application

    Hi I am new to Java and Netbeans.
    I am writing an java application which need to provide some services to PHP application. So I need webservices. In java application i do not provide any user-interface, all user interaction handled by PHP application.
    I have developed my required classes now it is time to expose this classes to PHP application. I wrote this classes in NetBeans 6.9 by creating Java-->Java Application not a web application. May i create webservices inside java application instead of web application ? How can i create SOAP webservices? Is there a good tutorial for netbeans 6.9 for webservices ?
    thanks for your help

    808551 wrote:
    Hi I am new to Java and Netbeans.
    I am writing an java application which need to provide some services to PHP application. So I need webservices. In java application i do not provide any user-interface, all user interaction handled by PHP application.
    I have developed my required classes now it is time to expose this classes to PHP application. I wrote this classes in NetBeans 6.9 by creating Java-->Java Application not a web application. May i create webservices inside java application instead of web application ?Yes, but where and how will you run that application?
    How can i create SOAP webservices? There are lots of different ways. One is to use Spring Web Services, another is to use JAX-WS
    Is there a good tutorial for netbeans 6.9 for webservices ?I don't think that you should google for something that is specific to netbeans. Just google for any tutorial that shows how to create web services.

  • Accessing XML Publisher Reports from Java application

    How to accesss the XDO Reports from Java application?
    I am wondering that we need to get the URL for accessing the report and call the URL with in Java program?
    Is that right? Is there any other option? Any help is greatly appreciated.

    You need to write some class based on the BI Publisher APIs taking data, template, output format, etc.
    Pehaps the following Blog of Tim Dexter shines some light on your question
    http://blogs.oracle.com/xmlpublisher/2007/02/27#a166
    Marcos

  • Send short message from Java application on mobile phone to server; http

    Hello!
    My question is: can I send short message from Java application on mobile phone to server - with the use of SMS (WMA) or http connection?
    I found this topic http://forums.sun.com/thread.jspa?threadID=5405431 about: "how to send data from midlet to servlet using doPost method".
    There is also such topic http://forums.sun.com/thread.jspa?threadID=5408046&tstart=0 about: "CLDC and MIDP - sending SMS to server -> Wireless Messaging API (WMA)".
    Please, kindly help me.
    Code from the topic mentioned above, edited by me so that it can be read easily:
    //http://forums.sun.com/thread.jspa?threadID=5405431
    //CLDC and MIDP - Re: how to send data from midlet to servlet using doPost method
    I want to know how to pass the values .
    for examples : this is what i wrote for doGet
    String url = setting.getUrl().toString()"/testProServlet/servlet/UpdateCompanyProfile?userId="+loggedInUserId"&svComp="saveCompHex;
    userId and svComp has the data which is very long so i wanted to use doPost.
    Now i dont know how to do it.
    This is what i have done in doGet (midlet)
    public void saveCompanyProfile(String saveComp,int flag,String blankFieldNm)
         System.out.println("flag===" flag);
         if (flag==1)
              displayAlert("Company Profile Edit",blankFieldNm+" field cannot be blank.",AlertType.ERROR, edCmpRecForm, true);
         else
              String saveCompHex = helper.encodeHexString(saveComp);
              // String saveCompHex =saveComp;
              HttpConnection httpConn = null;
              serverSettings setting = new serverSettings();
              System.out.println("saveCompHex===" saveCompHex);
              String url = setting.getUrl().toString()"/testProServlet/servlet/UpdateCompanyProfile?userId="loggedInUserId"&svComp="saveCompHex;
              System.out.println("url of save company profile:: "+url);
              InputStream is = null;
              OutputStream os = null;
              try {
                   // Open an HTTP Connection object
                   httpConn = (HttpConnection) Connector.open(url);
                   System.out.println("urlMidlet1 save edited company data===::" url.length());
                   // Setup HTTP Request
                   httpConn.setRequestMethod(HttpConnection.POST);
                   httpConn.setRequestProperty("User-Agent","Profile/MIDP-1.0 Confirguration/CLDC-1.0");
                   System.out.println("urlMidlet2===" url);
                   int respCode = httpConn.getResponseCode();
                   System.out.println("respCode edit company profile=====" respCode);
                   if (respCode == httpConn.HTTP_OK)
                        StringBuffer sb = new StringBuffer();
                        os = httpConn.openOutputStream();
                        is = httpConn.openDataInputStream();
                        int chr;
                        while ((chr = is.read()) != -1)
                             sb.append((char) chr);
                        String sResultSvCompanyProfile= sb.toString();
                        System.out.println("+++++++++++++Company sResult+++++++++++++==="sResultSvCompanyProfile);
                        if (resultViewCompanyProfile.trim().equals(""))
                             System.out.println("++++++++++++++If++++++++++++++SaveCompanyProfile===");
                             displayAlert("Login Incorrect","Username and Password incorrect", AlertType.ERROR, mainForm, true);
                        else
                             System.out.println("++++++++++++++Else++++++++++++++SaveCompanyProfile===");
                             //companyProfile();
                             displayAlert1("Information","Company Profile edited successfully", AlertType.INFO, profileMenuScreen, true);
                   else
                        System.out.println("Error in opening HTTP Connection. Error#" respCode);
                        //the line below divided into two lines because it was too long
                        displayAlert("Connection Failed","Cannot connect to server, please contact the Administrator.",
                        AlertType.ERROR, mainForm, false);
              catch(IOException e)
                   e.getMessage();
              finally {
                   if(is!= null)
                        try
                             is.close();
                        catch (IOException e)
                             // TODO Auto-generated catch block
                             e.printStackTrace();
                             displayAlert("Connection Failed","Cannot connect to server, please contact the Administrator.",
                             AlertType.ERROR, mainForm, false);
                   if(os != null)
                        try
                             os.close();
                        catch (IOException e)
                             // TODO Auto-generated catch block
                             e.printStackTrace();
                             displayAlert("Connection Failed","Cannot connect to server, please contact the Administrator.",
                             AlertType.ERROR, mainForm, false);
                   if(httpConn != null)
                        try
                             httpConn.close();
                        catch (IOException e)
                             // TODO Auto-generated catch block
                             e.printStackTrace();
                             displayAlert("Connection Failed","Cannot connect to server, please contact the Administrator.",
                             AlertType.ERROR, mainForm, false);
              } //end finally
         } //end else (?)
    } //end savecompany

    hi,
    SMS API(WMA) is an optional package. It is not a MIDP1.0 or MIDP2.0 api's.
    There are phones which has WMA api with MIDP1.0 support .... Nokia 3650
    Seimens has some phone with their own api's to send sms.Check out seimens site for more info
    BTW, What do you mean buy sending SMS to Server????
    If you want to send message to server you can do it with Http.
    HTH
    phani

  • Can we run EXE file/ Another Java Program from Java Application? How?

    Can we run EXE file and another java program from java application?
    Thanks in advance

    Example running adobe acrobat
    String command = "C:\\Program Files\\Adobe\\Acrobat 5.0\\Reader\\AcroRd32.exe /t "+selectedDocument+" \\\\CONTROL\\HP LaserJet 4L";
    Runtime rn = Runtime.getRuntime();
    Process process = rn.exec(command);
    process.waitFor();rykk

  • How to invoke dos shell from java program

    Hi,
    I'm not able to invoke dos shell from java.
    Can any one help me in this issue.
    I'm providing the source code below:
    try{
    Runtime.getRuntime().exec("cmd.exe")
    catch(IOException e) {
    System.out.println(e.getStackTrace());
    Thanks

    Does it throw a different exception?
    Or does it just do nothing at all?
    It does nothing at all[/b
    Is this a standalone Java app?
    Or a Java Applet running via a webbrowser? [b]It's a standalone application

  • How to call javascript from java application

    How can we call a function written in javascript from java application (core java not applet)? How will java identify javascript?
    Is there any such options ?

    Try creating a page called launcher.html (for example). That does this:
    <html>
    <head>
    <script language="javascript">
    windowHandle=window.open("http://www.javasoft.com", "", "height=700,width=1000,status=no,scrollbars=yes,resizable=yes,toolbar=no,menubar=no,location=no,top=5,left=5");
    </script>
    </head>
    </html>Now you launch IE (or whatever) with this page using the Runtime class. After x seconds (after the second window has been launched) try killing the process. Hopefully it will kill the original window you opened and not the window you popup (the one without toolbars etc)
    It might kill both windows but I can't be bothered to test it. If it does you'll have to try and find a workaround.

  • How to invoke BPEL process from JAVA API

    Hi Guys
    Any idea if you can tell me how to invoke BPEL process from JAVA API ?
    What to do in BPEL process manager to achieve that?
    Regards
    Deepak

    See http://download-west.oracle.com/docs/cd/B31017_01/integrate.1013/b28981/invoke.htm#sthref1373 and the JavaDocs http://download-west.oracle.com/docs/cd/B31017_01/integrate.1013/b28986/toc.htm.

Maybe you are looking for

  • Acrobat X not installing in Word 2010 toolbar

    Using Windows 7, 64-bit, and Office 2010 64-bit version. Just installed Acrobat X Pro and it is not installing Acrobat into the Word 2010 toolbar, can't locate any Acrobat items in the Word toolbar/com add-in/ribbon menus. I have installed it success

  • Error due to ORDER BY clause

    Hi gurus I have this formula for a Formula Column function CF_PREVIOUS_QUANTITY return Number is quantity number; begin SELECT QUANTITY_REMAINING INTO quantity FROM SELECT QUANTITY_REMAINING FROM ... WHERE .... ----ORDER BY trx_date DESC WHERE rownum

  • Postcode can't replicate to CRM from ECC

    hi,guys,    I found the postcode field and city field could not replicate to CRM from ECC,but other fields can replicate conrrectly.why?Our CRM system is 7.0 EHP1.

  • SCRIPTS vs smartforms

    how to differentiate between sapscripts and smartforms, what are the situations when one is used over other. how should we decide whether to go for sapscripts or smartform. plz describe the diferntiation

  • Windows 7 and Airport Extreme disk do not connect

    I have three windows computers (XP, VISTA & 7) and one mac mini all sharing a drive connected to my airport extreme. I can access the drive fine with computers except windows 7. My configuration on the airport was to prompt for a disk password, so I