Consume ABAP Webservice using AJAX javascript

Hi,
We created webservice for  ABAP BAPI. And I want to consume this using AJAX javascript.
But I am getting "Access Denied" javascript error.
Please let me know how to pass the credentials while trying to consume this webservice
I tried below code, but its NOT workng
var URL ="http://hostname/sap/bc/srt/rfc/sap/servicename?sap-client=400&sap-user=testuser&sap-password=testpassword";
xmlhttprequest.open("POST", URL, true);
Please let me know your thoughts ...
Thanks
Edited by: sona p on Feb 27, 2010 12:18 AM

Hi,
Thanks for your response. I did the same as mentioned in the link provided by you. But it is not working . I am still getting "Access denied" javascript error in the second line ( xmlhttprequest.open) . Below is my code.
var auth = make_base_auth('userid','password');
xmlhttprequest.open("POST", URL, true);
xmlhttprequest.setRequestHeader('Authorization', auth);
xmlhttprequest.setRequestHeader ("Content-Type", "text/xml");
xmlhttprequest.onreadystatechange = getDataList;
xmlhttprequest.send(SOAPEnvelope);
Please let me know your thoughts. Thanks again for your response.

Similar Messages

  • Consuming ABAP Webservice in Webdynpro app

    Hi,
    I have wrote a webdynpro app for consuming ABAP webservice. I used the procedure in the link below
    http://wiki.sdn.sap.com/wiki/display/WDJava/ConsumingABAPWebServiceinJavaWD
    Everything seemed to be went well, I created model and Webservice destinations. I have written the code for calling the webservice, which does not return data as part of response. I mean though the RFC returns data at the backend,its not showing the returned records in the webdynpro table.
    I have also tried checking the same by setting external break point. when the webservice is executed from my webdynpro app,it goes to the ABAP debugger and i could clearly see the records in the export parameters of RFC,but the same is not returned in the reponse object.
    Could any one let me know what could be missing. Any help is greatly appreciated?
    I have used the following code in Init method of my View
    Request_ZMYRFC input=new Request_ZMYRFC (model);
    wdContext.nodeRequest_ZMYRFC ().bind(input);
    ZMYRFC  req= new ZMYRFC (model);
    req.setPUserid("EDLAS00C");
    req.setPLtc("E");
    input.setMYRFC (req);
    IWDMessageManager manager = wdComponentAPI.getMessageManager();
        try
        wdContext.currentRequest_ZMYRFCElement().modelObject().execute();
          wdContext.nodeResponse().invalidate();
          wdContext.nodeZMYRFCResponse().invalidate();
          wdContext.nodeReturn_res().invalidate();
         wdContext.nodeItem_res_ret().invalidate();
          wdContext.nodeILtcg_res().invalidate();
          wdContext.nodeItem_res_ltcg().invalidate();
        catch(Exception e)
          manager.reportException(e.getMessage(), false);
    Thanks
    Santhosh

    santosh,
    Check provider system defination in nwa for webservice.After this mapp the provider system and service group after wd app deployed.This is mandatory while consuming webservice in webdynpro for latest versions of CE7.11 or later.for reference check this article/document. http://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/50d70a19-45a3-2b10-bba0-807d819daf46
    Thanks,
    Murthy.
    Edited by: Murthy Karaka on Mar 22, 2010 12:59 PM

  • How to consume REST WebService using Axis2 in Adobe CQ5.5

    Hi All,
        How to consume REST WebService using Axis2 in Adobe CQ5.5 ?
    Please help me with this.Thanks very much for your help.
    Thanks & Regards,
    Kumar

    We had enough trouble getting the "osgi compliant" Axis2 library to run in OSGI without spooky failures that we ended up re-writing everything utilizng JAX-WS. JAX-WS is present in the underlying JDK, you just need to create an OSGI fragment bundle that exposes these classes from the JDK. So basically a bundle that just exports:
    com.sun.xml.ws,
                                    com.sun.xml.ws.addressing,
                                    com.sun.xml.ws.addressing.model,
                                    com.sun.xml.ws.addressing.v200408,
                                    com.sun.xml.ws.api,
                                    com.sun.xml.ws.api.addressing,
                                    com.sun.xml.ws.api.client,
                                    com.sun.xml.ws.api.fastinfoset,
                                    com.sun.xml.ws.api.handler,
                                    com.sun.xml.ws.api.message,
                                    com.sun.xml.ws.api.message.stream,
                                    com.sun.xml.ws.api.model,
                                    com.sun.xml.ws.api.model.soap,
                                    com.sun.xml.ws.api.model.wsdl,
                                    com.sun.xml.ws.api.pipe,
                                    com.sun.xml.ws.api.pipe.helper,
                                    com.sun.xml.ws.api.server,
                                    com.sun.xml.ws.api.streaming,
                                    com.sun.xml.ws.api.wsdl.parser,
                                    com.sun.xml.ws.api.wsdl.writer,
                                    com.sun.xml.ws.binding,
                                    com.sun.xml.ws.client,
                                    com.sun.xml.ws.client.dispatch,
                                    com.sun.xml.ws.client.sei,
                                    com.sun.xml.ws.developer,
                                    com.sun.xml.ws.developer.servlet,
                                    com.sun.xml.ws.encoding,
                                    com.sun.xml.ws.encoding.fastinfoset,
                                    com.sun.xml.ws.encoding.soap,
                                    com.sun.xml.ws.encoding.soap.streaming,
                                    com.sun.xml.ws.encoding.xml,
                                    com.sun.xml.ws.fault,
                                    com.sun.xml.ws.handler,
                                    com.sun.xml.ws.message,
                                    com.sun.xml.ws.message.jaxb,
                                    com.sun.xml.ws.message.saaj,
                                    com.sun.xml.ws.message.source,
                                    com.sun.xml.ws.message.stream,
                                    com.sun.xml.ws.model,
                                    com.sun.xml.ws.model.soap,
                                    com.sun.xml.ws.model.wsdl,
                                    com.sun.xml.ws.org.objectweb.asm,
                                    com.sun.xml.ws.protocol.soap,
                                    com.sun.xml.ws.protocol.xml,
                                    com.sun.xml.ws.resources,
                                    com.sun.xml.ws.server,
                                    com.sun.xml.ws.server.provider,
                                    com.sun.xml.ws.server.sei,
                                    com.sun.xml.ws.server.servlet,
                                    com.sun.xml.ws.spi,
                                    com.sun.xml.ws.streaming,
                                    com.sun.xml.ws.transport,
                                    com.sun.xml.ws.transport.http,
                                    com.sun.xml.ws.transport.http.client,
                                    com.sun.xml.ws.transport.http.server,
                                    com.sun.xml.ws.transport.http.servlet,
                                    com.sun.xml.ws.util,
                                    com.sun.xml.ws.util.exception,
                                    com.sun.xml.ws.util.localization,
                                    com.sun.xml.ws.util.pipe,
                                    com.sun.xml.ws.util.xml,
                                    com.sun.xml.ws.wsdl.parser,
                                    com.sun.xml.ws.wsdl.writer,
                                    com.sun.xml.ws.wsdl.writer.document,
                                    com.sun.xml.ws.wsdl.writer.document.http,
                                    com.sun.xml.ws.wsdl.writer.document.soap,
                                    com.sun.xml.ws.wsdl.writer.document.soap12,
                                    com.sun.xml.ws.wsdl.writer.document.xsd,
                                    com.sun.xml.internal.bind,
                                    com.sun.xml.internal.bind.v2,
                                    com.sun.xml.internal.ws,
                                    com.sun.xml.internal.ws.addressing,
                                    com.sun.xml.internal.ws.addressing.model,
                                    com.sun.xml.internal.ws.addressing.v200408,
                                    com.sun.xml.internal.ws.api,
                                    com.sun.xml.internal.ws.api.addressing,
                                    com.sun.xml.internal.ws.api.client,
                                    com.sun.xml.internal.ws.api.fastinfoset,
                                    com.sun.xml.internal.ws.api.handler,
                                    com.sun.xml.internal.ws.api.message,
                                    com.sun.xml.internal.ws.api.message.stream,
                                    com.sun.xml.internal.ws.api.model,
                                    com.sun.xml.internal.ws.api.model.soap,
                                    com.sun.xml.internal.ws.api.model.wsdl,
                                    com.sun.xml.internal.ws.api.pipe,
                                    com.sun.xml.internal.ws.api.pipe.helper,
                                    com.sun.xml.internal.ws.api.server,
                                    com.sun.xml.internal.ws.api.streaming,
                                    com.sun.xml.internal.ws.api.wsdl.parser,
                                    com.sun.xml.internal.ws.api.wsdl.writer,
                                    com.sun.xml.internal.ws.binding,
                                    com.sun.xml.internal.ws.client,
                                    com.sun.xml.internal.ws.client.dispatch,
                                    com.sun.xml.internal.ws.client.sei,
                                    com.sun.xml.internal.ws.developer,
                                    com.sun.xml.internal.ws.encoding,
                                    com.sun.xml.internal.ws.encoding.fastinfoset,
                                    com.sun.xml.internal.ws.encoding.soap,
                                    com.sun.xml.internal.ws.encoding.soap.streaming,
                                    com.sun.xml.internal.ws.encoding.xml,
                                    com.sun.xml.internal.ws.fault,
                                    com.sun.xml.internal.ws.handler,
                                    com.sun.xml.internal.ws.message,
                                    com.sun.xml.internal.ws.message.jaxb,
                                    com.sun.xml.internal.ws.message.saaj,
                                    com.sun.xml.internal.ws.message.source,
                                    com.sun.xml.internal.ws.message.stream,
                                    com.sun.xml.internal.ws.model,
                                    com.sun.xml.internal.ws.model.soap,
                                    com.sun.xml.internal.ws.model.wsdl,
                                    com.sun.xml.internal.ws.org.objectweb.asm,
                                    com.sun.xml.internal.ws.protocol.soap,
                                    com.sun.xml.internal.ws.protocol.xml,
                                    com.sun.xml.internal.ws.resources,
                                    com.sun.xml.internal.ws.server,
                                    com.sun.xml.internal.ws.server.provider,
                                    com.sun.xml.internal.ws.server.sei,
                                    com.sun.xml.internal.ws.spi,
                                    com.sun.xml.internal.ws.streaming,
                                    com.sun.xml.internal.ws.transport,
                                    com.sun.xml.internal.ws.transport.http,
                                    com.sun.xml.internal.ws.transport.http.client,
                                    com.sun.xml.internal.ws.transport.http.server,
                                    com.sun.xml.internal.ws.util,
                                    com.sun.xml.internal.ws.util.exception,
                                    com.sun.xml.internal.ws.util.localization,
                                    com.sun.xml.internal.ws.util.pipe,
                                    com.sun.xml.internal.ws.util.xml,
                                    com.sun.xml.internal.ws.wsdl.parser,
                                    com.sun.xml.internal.ws.wsdl.writer,
                                    com.sun.xml.internal.ws.wsdl.writer.document,
                                    com.sun.xml.internal.ws.wsdl.writer.document.http,
                                    com.sun.xml.internal.ws.wsdl.writer.document,
                                    com.sun.xml.internal.ws.wsdl.writer.document.soap,
                                    com.sun.xml.internal.ws.wsdl.writer.document.soap12,
                                    com.sun.xml.internal.ws.wsdl.writer.document.xsd,
                                    com.sun.xml.internal.messaging.saaj.soap

  • Consuming a WebService using OSR (uddi) endpoint

    Hey folks,
    I'm trying to consume a WebService declaratively in my ADF taskflow, using a WebService Proxy connection in my model project, as the guides/tutorials told me to. However, I don't have the final endpoint of the service as it is registered in the OSR (Oracle Service Registry) and all I have is its UDDI key.
    So, in fact, my application must connect to OSR to get the service endpoint based on the uddi key and then resolve the port binding based on that.
    Any ideas on how I can perform this?
    Thanks in advance!

    This article helped me out! So if you came here with the same problem, here's some light!
    http://biemond.blogspot.co.uk/2009_12_01_archive.html

  • Consuming ABAP Webservice from Android device

    Dear Experts,
    I am ABAP developer (limited knowledge on android) trying to connect  Android device to a.SAP Webservice
    Through trial and error and help from SDN and Android forums i managed to link up the ABAP webservice and android using KSOAP2 API.Its working perfectly now but only when i save the username password for SAP access in the webservice settings in transaction SICF.I need to access the service by passing the username and password values through the SOAP request header but so far my efforts have failed me.im presently using the following code to pass my auth values.
    I would be grateful if you can point me in the proper direction.
           String NAMESPACE = "mynamespace (works properly without auth)";
            String METHOD_NAME = "mymethod (works properly without auth)";
            String SOAP_ACTION = "mynamespace/mymethod (works properly without auth)";
            String URL = "myURL{works properly without auth)";
            SoapObject Request = new SoapObject(NAMESPACE, METHOD_NAME);
            Request.addProperty("Purchaseorder","4500001168");
            Request.addProperty("Username", "myusername");
            Request.addProperty("Password", "mypassword");
           SoapSerializationEnvelope envelope = new SoapSerializationEnvelope(SoapEnvelope.VER11);
           envelope.setOutputSoapObject(Request);
           HttpTransportSE androidHttpTransport = new HttpTransportSE(URL);
    try
               androidHttpTransport.call(SOAP_ACTION, envelope);
               SoapObject response = (SoapObject)envelope.bodyIn;
               String testValue =  response.getProperty("PoHeader").toString();
               AlertDialog alertDialog = new AlertDialog.Builder(this).create();
               alertDialog.setMessage(testValue);     
               alertDialog.show();
           catch(Exception e)
                e.printStackTrace();
    Thanx & Best Regards

    Hi,
    you can develop a custom Transport class wich extends the: HttpTransportSE class by authentication features.
    example:
    public class AuthTransportSE extends HttpTransportSE{
         private String username;
         private String password;
         public AuthTransportSE(String url, String username, String password) {
              super(url);
              this.username = username;
              this.password = password;          
         protected ServiceConnection getServiceConnection() throws IOException {
              ServiceConnection midpConnection = new ServiceConnectionSE(url);
              addBasicAuthentication(midpConnection);
              return midpConnection;
         protected void addBasicAuthentication(ServiceConnection midpConnection) throws IOException {
            if (username != null && password != null) {
                StringBuffer buf = new StringBuffer(username);
                buf.append(':').append(password);
                byte[] raw = buf.toString().getBytes();
                buf.setLength(0);
                buf.append("Basic ");
                org.kobjects.base64.Base64.encode(raw, 0, raw.length, buf);
                midpConnection.setRequestProperty("Authorization", buf.toString());
    Afterwards you can initialize the Webservice with:
    AuthTransportSE androidHttpTransport = new AuthTransportSE(URL, userName, pasword);
    Cheers,
    Dennis.

  • ABAP webservices using 2 wsdl

    Hi,
    SAP is  initiating a SOAP request to  DataPower ESB which gets an asynchronous  SOAP response  and gives it back to SAP.
    It is a pass through service  and there is no transformation done.
    SAP is creating ABAP webservices. The webservices are created using the request wsdl currently. Can it be done using 2 wsdl as request wsdl and response wsdls are different. Combining them is another option but later on the provider changes the wsdl , the wsdl again needs to be combined . Instead of that can we maintain 2 different wsdl one for request and one for response and create ABAP webservices.
    Kindly suggest.

    Hi,
    Since this is async communication you can make two services in ABAP using 2 different wsdl. These two wsdls are two different services (in your case).
    Regards,
    Gourav

  • Consuming peoplesoft webservices using JSF application gives error

    Hi,
    I am using Jdeveloper 11g to consume a peoplesoft webservice which does the basic datbase operations.
    I have been successful in creating a proxy using the wsdl file and using JAX-WS approach to achieve the same.
    I can connect to the webservice using the proxy client.
    But when i package the proxy( create a jar) and import in my web application (JSF application), i am running into following error.
    <ActionListenerImpl><processAction> com.sun.xml.ws.streaming.XMLStreamReaderException: unexpected XML tag. expected: {http://peoplesoft.com/KCM_WEB_CASE_CI}Get__CompIntfc__KCM_WEB_CASE_CIResponse but found: {http://schemas.xmlsoap.org/ws/2002/xx/secext}Get__CompIntfc__KCM_WEB_CASE_CIResponse
    javax.faces.el.EvaluationException: com.sun.xml.ws.streaming.XMLStreamReaderException: unexpected XML tag. expected: {http://peoplesoft.com/KCM_WEB_CASE_CI}Get__CompIntfc__KCM_WEB_CASE_CIResponse but found: {http://schemas.xmlsoap.org/ws/2002/xx/secext}Get__CompIntfc__KCM_WEB_CASE_CIResponse
         at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
         at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
         at javax.faces.component.UICommand.broadcast(UICommand.java:387)
         at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
         at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
         at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
         at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
         at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
         at javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
         at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
         at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
         at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:300)
         at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.dms.wls.DMSServletFilter.doFilter(DMSServletFilter.java:330)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:27)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.doIt(WebAppServletContext.java:3684)
         at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3650)
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
         at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121)
         at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2268)
         at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2174)
         at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1446)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    Caused by: com.sun.xml.ws.streaming.XMLStreamReaderException: unexpected XML tag. expected: {http://peoplesoft.com/KCM_WEB_CASE_CI}Get__CompIntfc__KCM_WEB_CASE_CIResponse but found: {http://schemas.xmlsoap.org/ws/2002/xx/secext}Get__CompIntfc__KCM_WEB_CASE_CIResponse
         at com.sun.xml.ws.streaming.XMLStreamReaderUtil.verifyTag(XMLStreamReaderUtil.java:214)
         at com.sun.xml.ws.streaming.XMLStreamReaderUtil.verifyTag(XMLStreamReaderUtil.java:222)
         at com.sun.xml.ws.client.sei.ResponseBuilder$DocLit.readResponse(ResponseBuilder.java:531)
         at com.sun.xml.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:127)
         at com.sun.xml.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:95)
         at com.sun.xml.ws.client.sei.SEIStub.invoke(SEIStub.java:135)
         at $Proxy135.getCompIntfcKCMWEBCASECI(Unknown Source)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:597)
         at weblogic.wsee.jaxws.spi.ClientInstance$ClientInstanceInvocationHandler.invoke(ClientInstance.java:363)
         at $Proxy136.getCompIntfcKCMWEBCASECI(Unknown Source)
         at project1.proxy.KCM_WEB_CASE_CISoapClient.getKCMMethod_final(KCM_WEB_CASE_CISoapClient.java:618)
         at login.view.Handler.CRMSearchHandler.getSearchResults(CRMSearchHandler.java:18)
         at login.view.backing.Login.search(Login.java:54)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:597)
         at com.sun.el.parser.AstValue.invoke(AstValue.java:157)
         at com.sun.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:283)
         at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
    I am not sure what else i need to import or rather how to package the proxy classes to get it working.
    Any help will be highly appreciated.
    I even tried creating a webservice proxy in the JSF project instead of importing the jar, yet i am getting the same error, but the irony is that when i run just the proxy class(standalone with main method) i can get access to the webservice.
    Thanks
    Ash
    Edited by: [email protected] on Jun 8, 2010 2:38 PM

    Well,
    There is a issue with analyzer capturing SOAP traffic when using with secure proxies, so that is why you are not seeing any data there.
    And I think if you will try your jax-rpc code again, it might work as there was nothing incorrect in your code, so might be that the whole config was corrupt which was throwing out incorrect error(s).
    About a web service with credentials, you can quickly create one.
    Have a java class like the following:
    import javax.jws.WebService;
    import weblogic.jws.Policy;
    @WebService
    @Policy(uri = "policy:Wssp1.2-2007-Https-UsernameToken-Plain.xml")
    public class Class1 {
    public Class1() {
    super();
    public String sayHello() {
    return "Hi";
    The procy code for this will be something like:
    private static Class1Service class1Service;
    public static void main(String[] args) {
    try {
    class1Service = new Class1Service();
    Class1 class1 = class1Service.getClass1Port();
    Map<String, Object> requestContext = ((BindingProvider) class1).getRequestContext();
    setPortCredentialProviderList(requestContext);
    // Add your code to call the desired methods.
    System.out.println(class1.sayHello());
    } catch (Exception ex) {
    ex.printStackTrace();
    public static void setPortCredentialProviderList(Map<String, Object> requestContext) throws Exception {
    // TODO - Provide the required values
    String username = "weblogic";
    String password = "weblogic1";
    List<CredentialProvider> credList = new ArrayList<CredentialProvider>();
    // Add the necessary credential providers to the list
    credList.add(getUNTCredentialProvider(username, password));
    //credList.add(getBSTCredentialProvider(clientKeyStore, clientKeyStorePassword, clientKeyAlias, clientKeyPassword, serverKeyStore, serverKeyStorePassword, serverKeyAlias, requestContext));
    //credList.add(getSAMLTrustCredentialProvider());
    requestContext.put(WSSecurityContext.CREDENTIAL_PROVIDER_LIST, credList);
    Thanks,
    Vishal

  • Consuming WCF-Webservices using XI/PI

    Hello,
    I'am trying to consume a WCF-Webservice with the XI/PI. First I imported the WSDL of this webservice as an external definition - so far so good. But when I try to create a message-mapping, no fields are available and the XI/PI says something like "null-pointer exception". I suppose it's because there are no field definitions in the WSDL (seems, that the fields I'am missing are downloaded in the background when using anything other to test the webservice, eg. SoapUI).
    Can someone give me a hint how to comsume WCF-Services with the XI? Maybe it's a problem with the WSDL, but how can I put the fields/parameters into the WSDL?
    Thank in advance
    Thomas

    1.Once you import the WSDL under External Definition then you should be able to see the messages under the message tab which indicates input/output message types of your Web service
    2.If you are not sending any request and not expecting any response from web service then this message tab will be empty
    if web service contains reference to input and output strucuteres then PI editor can not refer them
    in that case do a copy the structure of messages into WSLD and reimport agian
    HTH
    Rajesh

  • Page reload using Ajax/ Javascript

    Hi All,
    I am new to Ajax, in my application i have to reload the page once i click on the link on a report column.
    Another one is how to call "On load process" by clicking on the report link.
    Can anybody help on this.
    thanx
    Madhu

    implement page submit with AJAX instead of javascriptSome comments
    <li>If you are submtting page, then you don't ajax coz you can do the processing in an Onsubmit PLSQL process
    <li>The J in AJAX stands for "Javascript."
    >
    My requirement is on clicking on the report column i have to call one javascript and in javascript i am setting item value then submitting the page with doSubmit, then it will run the onload process based on the item value.
    Again from onload process i am calling another javascript.
    >
    So "column link" -> "JS function" -> "SET Item" ->"Submit The Page" -> "on load process" ???
    If you are on apex 4.0 ,you can use Dynamic Action for such things
    <li> add a handler for the link column that can be used in identifying the link for instance
    by adding to the link attributes(in column properties)
    class="my_link"<li> Then add a Dynamic action that is fired when you click on the link
    Dynamic Action Name : Anything you want
    Triggering element type: jQuery Selector
    jQuery Selector: a.my_link
       True Action 1: Type : Javascript
             JS code : <Insert JS code  to set the item>
       True Action 1: *PLSQL*
            PLSQL source : <use the PSLQL code from your onload PLSQL process>
            Items to submit : <set item name>, <any other items being refered in PLSQL>

  • Consuming ABAP webservice in Java

    Hi Gurus,
    We are publishing webservices from SAP and Java team is consuming them. For accessing the webservice  from java , we are maintaining User name and Password in SICF for that service.
    Now if we donot maintain the User name and Password in SICF for that service then Exception "Unauthorised " is coming in Java.
    We want to pass the User name and Password from Java. How to achieve this.
    Thanks
    Jitendra

    Hi John,
    thnx for quick response. i have given WSDL to Java team but they are unable to find " Logon service in the WSDL".
    Can u tell us for which XML tags we should search.
    Thanks
    Jitendra

  • Consuming ABAP Webservice in webdynpro java.

    hi All,
    i tried the all ways provided in sdn to create a webservice in ABAP when i test its working fine on j2ee server.
    when i call the same webservice from webdynpro its throughing this error can any body kindly help me in this.
    java.rmi.RemoteException: Service call exception; nested exception is: com.sap.engine.services.webservices.jaxrpc.exceptions.InvalidResponseCodeException: Invalid Response Code: (502) Proxy Error ( The ISA Server denied the specified Uniform Resource Locator (URL).  ). The requested URL "xxxxxxxxxx".
    Thank you.
    venkat.

    Hi Venkatramana,
    The class of the ProxyGenerator is com.inqmy.lib.wsdl.ProxyGenerator. It is located in <SAPj2eeEngine_install_dir>/cluster/server/additional-lib/inqmysoap.jar or <SAPj2eeEngine_install_dir>/alone/additional-lib/inqmysoap.jar file. In addition the following JAR files must be included in your classpath - mail.jar, activation.jar, inqmyxml.jar, inqmysoap.jar, located in <SAPj2eeEngine_install_dir>/cluster/server/additional-lib/ or <SAPj2eeEngine_install_dir>/alone/additional-lib/ directory. You need also the inqmy-lib.jar file in <SAPj2eeEngine_install_dir>/cluster/server/lib/ or <SAPj2eeEngine_install_dir>/alone/lib/ directory in order to run the generator.
    SAP Note : <a href="https://websmp201.sap-ag.de/~form/handler?_APP=01100107900000000342&_EVENT=REDIR&_NNUM=547847&_NLANG=E">547847</a>
    Before deploying make sure the JCo’s are up and running
    Go to http://server:port/webdynpro/dispatcher/sap.com/tcwdtools/Explorer to check the status of JCo’s.
    Regards,
    Mithu

  • Consuming a webservice using Webservice model in Webdynpro

    Hi all,
    I am working on a scenario where in XI is used for calling Remote Function Module of R3 system using SOAP
    My XI Consultant has implemented SOAP to RFC scenario in XI succesfully and generated the WSDL file in XI.
    I got that WSDL file and saved locally on my desktop.
    I created a Webservice model based on the local WSDL file and then gave necessary inputs and also included the following code for the SOAP call to happen
    wdContext.currentRequest_Soap2Rfc_Ob_MiElement().modelObject().execute();
      wdContext.nodeResponse().invalidate();
      wdContext.nodeRes_Mt().invalidate();
    When I tried to give input data and click on submit it is calling the model object execute method and is throwing the following exception
    Exception on execution of web service with WSDL URL 'C:\Documents and Settings\aljsed01\Desktop\soap2rfc_ob_mi.wsdl' with operation 'soap2rfc_ob_mi' in interface 'soap2rfc_ob_mi'
    Does any have any idea about this?
    Should I require some more steps to do?
    Anyhelp in this regard is highly appreciated
    Regards,
    Santhosh

    Hi Anil and Rahul,
    Thanks a lot for your help and time.
    I have created destinations one for metadata and the other for Execution.
    But I am not sure of what URL to be given
    I have my WSDL file locally on the system.If I give that path,it says wrong protocol.
    And if I give XI URL,it does not pick up metada shows some other error.
    What URL should I need to give for locally saved WSDL??Please suggest
    And Rahul,here is the WSDL file which my XI consultant gave
    Let me know if it is ok.
    <?xml version="1.0" encoding="UTF-8"?>
    <wsdl:definitions xmlns:p1="http://soap2rfcns" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" name="soap2rfc_ob_mi" targetNamespace="http://soap2rfcns">
    +     <wsdl:types>+
    +          <xsd:schema targetNamespace="http://soap2rfcns" xmlns="http://soap2rfcns" xmlns:xsd="http://www.w3.org/2001/XMLSchema">+
    +               <xsd:element name="res_mt" type="res_dt"/>+
    +               <xsd:element name="req_mt" type="req_dt"/>+
    +               <xsd:complexType name="req_dt">+
    +                    <xsd:annotation>+
    +                         <xsd:appinfo source="http://sap.com/xi/TextID">0f2ee199b2ce11dca877001a4bf038d4</xsd:appinfo>+
    +                    </xsd:annotation>+
    +                    <xsd:sequence>+
    +                         <xsd:element name="airlineid" type="xsd:string">+
    +                              <xsd:annotation>+
    +                                   <xsd:appinfo source="http://sap.com/xi/TextID">f17dde30b2cd11dcb5f6001b78b0798a</xsd:appinfo>+
    +                              </xsd:annotation>+
    +                         </xsd:element>+
    +                         <xsd:element name="connectid" type="xsd:string">+
    +                              <xsd:annotation>+
    +                                   <xsd:appinfo source="http://sap.com/xi/TextID">f17dde31b2cd11dcbcd8001b78b0798a</xsd:appinfo>+
    +                              </xsd:annotation>+
    +                         </xsd:element>+
    +                         <xsd:element name="fldate" type="xsd:date">+
    +                              <xsd:annotation>+
    +                                   <xsd:appinfo source="http://sap.com/xi/TextID">f17dde32b2cd11dc986c001b78b0798a</xsd:appinfo>+
    +                              </xsd:annotation>+
    +                         </xsd:element>+
    +                    </xsd:sequence>+
    +               </xsd:complexType>+
    +               <xsd:complexType name="res_dt">+
    +                    <xsd:sequence>+
    +                         <xsd:element name="econofree" type="xsd:integer">+
    +                              <xsd:annotation>+
    +                                   <xsd:appinfo source="http://sap.com/xi/TextID">6906c250b2ce11dca99e001b78b0798a</xsd:appinfo>+
    +                              </xsd:annotation>+
    +                         </xsd:element>+
    +                         <xsd:element name="bussfree" type="xsd:integer">+
    +                              <xsd:annotation>+
    +                                   <xsd:appinfo source="http://sap.com/xi/TextID">6906c251b2ce11dc9996001b78b0798a</xsd:appinfo>+
    +                              </xsd:annotation>+
    +                         </xsd:element>+
    +                         <xsd:element name="firstfree" type="xsd:integer">+
    +                              <xsd:annotation>+
    +                                   <xsd:appinfo source="http://sap.com/xi/TextID">6906c252b2ce11dc9c70001b78b0798a</xsd:appinfo>+
    +                              </xsd:annotation>+
    +                         </xsd:element>+
    +                    </xsd:sequence>+
    +               </xsd:complexType>+
    +          </xsd:schema>+
    +     </wsdl:types>+
    +     <wsdl:message name="req_mt">+
    +          <wsdl:part name="req_mt" element="p1:req_mt" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"/>+
    +     </wsdl:message>+
    +     <wsdl:message name="res_mt">+
    +          <wsdl:part name="res_mt" element="p1:res_mt" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"/>+
    +     </wsdl:message>+
    +     <wsdl:portType name="soap2rfc_ob_mi">+
    +          <wsdl:operation name="soap2rfc_ob_mi">+
    +               <wsdl:input message="p1:req_mt"/>+
    +               <wsdl:output message="p1:res_mt"/>+
    +          </wsdl:operation>+
    +     </wsdl:portType>+
    +     <wsdl:binding name="soap2rfc_ob_miBinding" type="p1:soap2rfc_ob_mi" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">+
    +          <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"/>+
    +          <wsdl:operation name="soap2rfc_ob_mi">+
    +               <soap:operation soapAction="http://sap.com/xi/WebService/soap1.1" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"/>+
    +               <wsdl:input>+
    +                    <soap:body use="literal" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"/>+
    +               </wsdl:input>+
    +               <wsdl:output>+
    +                    <soap:body use="literal" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"/>+
    +               </wsdl:output>+
    +          </wsdl:operation>+
    +     </wsdl:binding>+
    +     <wsdl:service name="soap2rfc_ob_miService">+
    +          <wsdl:port name="soap2rfc_ob_miPort" binding="p1:soap2rfc_ob_miBinding" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">+
    +               <soap:address location="http://sapxidev:50000/XISOAPAdapter/MessageServlet?channel=:BS_SS:req_cc&version=3.0&Sender.Service=BS_SS&Interface=http%3A%2F%2Fsoap2rfcns%5Esoap2rfc_ob_mi" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"/>+
    +          </wsdl:port>+
    +     </wsdl:service>+
    </wsdl:definitions>
    Rgds,
    Santhosh

  • ABAP webservices using XIF adapter in SAP CRM?

    Hi,
    We are going to invoke SAP CRM objects web services via SOAP. Do I need a J2EE engine? Can't I do it with ABAP engine? Without J2EE engine is it difficult to figure out the details of WSDLs to use? If so how..
    Thanks,
    Vijay
    Edited by: Vijay Mudivedu on May 29, 2008 3:33 PM
    Edited by: Vijay Mudivedu on May 29, 2008 3:57 PM

    yes you need J2EE engine
    Regards,
    RDS

  • Consume webservice using HTTP adapter

    Hi PI Experts,
    Can we consume a webservice using a HTTP adapter?
    If yes can anyone share some knowledge, how to do so?
    Thanks & REgards,
    Krishna

    Hi Krishna,
    I think this can be done using FLEX.(not sure).
    Ref:  http://wiki.sdn.sap.com/wiki/display/EmTech/ConsumingABAPWebServicesusing+Flex
    Thanks,

  • Consuming external webservice in an automated activity

    hi,
    i am consuming a bapi based webservice in an automated activity. i have checked this in wsnavigator using WSDL, it is working fine. when i consume this in my process dc , it asks me to create aService group. i have created one and now deployed dc to server. it doesn't work and in log error it shows that thsi service group is not assigned to any physical system.
    now i tried to create a business scenario communication, for this i created provider systems (it was created and pinged sucessfully, showed all the web services lying in its service registry). when i was creating business scenario, under first step credentials of service group and provider systems are provided. unser second step when i tried to add the services it didn't showed the services which it showed me while i pinged.
    please tell me how to sucessfully consume an external web service (bapi based).This is lying on SR but when i tried to access it through single service administration, it was not there. please guide me how can i sucessfully consume this webservice (using service group or logical destination).
    Thanks In Advance.

    Hi Rohit,
    try with Application Communication Configuration instead of Business Scenario (should be easier for single service). Make sure you have entered the correct credentials for the backend system (both for metadata retrieval and for runtime invocation).
    Instead of Service Registry you can also try with WSIL when creating the provider system. The WSIL URL for the ABAP system should look like this: http://host:port/sap/bc/srt/wsil.
    Please also check the SOA config guide by Alexander Zubev:
    http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/40dabb46-dd66-2b10-1a9a-81aa620098b3
    Hope this helps,
    Christian
    Edited by: Christian Loos on Dec 29, 2009 10:28 AM

Maybe you are looking for

  • PDF Report - Fonts not displayed

    Some of the PDF reports which display correctly, after being edited, don't display the text in the output PDF. This issue is happening when run as a concurrent request in Oracle Apps 11i, but in local machine, the PDF report works fine. This is happe

  • System traycwith c#

    Hi, Can C#  retrive i a form the system tray programs and their icons??? Thanks!

  • Trouble exporting 11-min film as XML because of audio translation issue

    Hi, I am trying to export a short film XML file of approximately 11 minutes for a sound engineer and it's coming up with a ton of audio translation issues. Can I attach the report and someone help me? Most of the issues are audio tracks from ADR but

  • Premiere Pro CS3 Encoding Error

    I'm supporting an end user who has been using Premiere Pro CS3 for years to develop and encode videos on their computer. Recently, they have been experiencing an issue with one particular project they're been attempting to encode.  The project is not

  • Looking for sample java code for dvt:hierarchyViewer

    Hi. We currently use Jdeveloper 11g Build JDEVADF_11.1.1.1.0_GENERIC_090615.0017.5407 Recently, we have seen some nice demos for Manager-Employees tree. Here is one @ http://jdevadf.oracle.com/dvt-faces-demo/faces/dvtTagGuide/ariaXml.jspx?_adf.ctrl-s