CE 7.1 - How to call CAF services from Web Dynpro

Hi,
whats the suggested way to call caf services from web dynpro?
Of course I can use the Web Service model. But can I call caf directly?
I read something about caf web dynpro model, but I cannot find it in nwds 7.1. On some older tutorial it was in context menu of caf project, but it seems to be removed.
best regards
tom

Hi ,
The standard way is to use the web service model.
You have to expose the the services as web service and then you can use the wsdl url in the Adaptive web service model option.
The above option will be available when you click the Model in the webdynpro application and the click create new model.
Hope it helps you.
Regards,
Srinivasan Subbiah

Similar Messages

  • How to call BI report  from web dynpro

    Hi ,
    How to call  BI report from webdynpro application  and what are the prerequisites for that .
    Please provide an example to work with BI application frame UI element
    Thanks

    Hi Rajpal,
    Please go through this..
    calling BI report
    Cheers,
    Kris.

  • How to call t-code from web dynpro ABAP application

    Dear Gurus,
    I am new to ABAP web dynpros. I have to add a button and have to call a SAP standard t-code if user clicks on this button? How to accomplish this task? Any help or example would be appreciated.
    Thanks,
    GSM

    Hi GSM,
    You have to create a SAP transaction iView in your Portal, then obtain its URL in your webdynpro and call WDPortalNavigation.absolute() method.
    Below are the same steps in more detail:
    1) Create a SAP Transaction iView or an Internet Application Component iView (whichever you find convenient). While creating you can select whether you want to use SAP GUI for windows or SAP GUI for HTML. For the latter(GUI for HTML) ensure that your ITS is working fine and configured while creating the system in EP.
    2) Open the properties of the SAP transaction iView created. In the OK code field you can give the ok code value just as you give in SAP R/3 in case you want to navigate to the second screen of SAP R/3 when you pass values from WebDynpro.
    Example for the above would be say Transaction "VA03" for displaying Sales order. Suppose from Webdynpro i want to pass a parameter called "Order number" and when i click a button it should pass the order number to R/3 and skip the first screen required for inputting the sales order numbe.
    It should directly go to the main display of sales order for that ordernumber.
    3) Create your WebDynpro component and deploy it on the server. In your WebDynpro use the WDPortalNavigation.absolute() method and give the url of the SAP Transaction iView created as a parameter and also the required parameters that you would like to pass from WebDynpro.
    4) Create a SAP WebDynpro iView in the Portal.
    5) Now run the Component. It should open up your SAP Transaction iview.
    Regards,
    Uday

  • How to call business service from xquery transformation in OSB ??

    Hi All,
    How to call business service from xquery transformation in OSB ??
    I need to assign the response variable of Business Service to a target element in XQuery Transformation Mapper file.
    It's urgent.
    Regards,
    Jyoti Nayak

    Transformation is to mapping the source and target of 2 different schemas.
    In your case you should have a XQuery transformation between, your Business Service output schema and the target schema.
    Thanks,
    Vijay

  • How to call PDF file in Web Dynpro Appl?

    How to call PDF file in Web Dynpro Appl?

    Hi Gobinath,
    1. Create a value attribute of type byte called pdfSource.
    2. Insert an UI element called Interactive Form in your layout
    3. Set the source property of this Interactive From UI element to the context pdfSource.
    4. Insert a button which would open your pdf file.
    public void onActionsubmit(com.sap.tc.webdynpro.progmodel.api.IWDCustomEvent wdEvent )
        //@@begin onActionsubmit(ServerEvent)
       IPrivate<viewname>.IContextElement contextElement = wdContext.currentContextElement();
             byte[] bytes = contextElement.getPdfSource();
             try
                   File file = new File("C:
    temp
    example.pdf");
                   FileOutputStream os = new FileOutputStream(file);
                   os.write(bytes);
                   os.close();
                catch (IOException e)
                   // do something
                   e.printStackTrace();
        //@@end
    Warm Regards,
    Murtuza

  • Calling portal service from web service

    Hello,
    I'm trying to call portal service from web service. Is this possible? I'm getting an error.
    For example, code:
    IJCOClientService clientService = (IJCOClientService) PortalRuntime.getRuntimeResources().getService(IJCOClientService.KEY);
    .. is generating exception:
    java.lang.LinkageError: Class com/sapportals/portal/prt/runtime/IPortalRuntimeResources violates loader constraints
    Do anybody knows what's wrong?
    Best regards,
    Josef Motl

    Hi Josef,
    Is the IJCOClientService located on the producer side or on the consumer side?
    Amit

  • How to call a form from WEB.SHOW_DOCUMENT 10g  Is this possible?????

    how to call a form from WEB.SHOW_DOCUMENT
    I would like to call a form using the WEB.SHOW_DOCUMENT the idea is from the menu that is attached to the form instead of use call_form use WEB.SHOW_DOCUMENT(...my_newform.fmx)
    Is this possible?????

    Hi ,
    I think yes...but under some circumstances....
    In your formsweb.cfg file you should define a named configuration alias... such as:
    [TEST]
    workingDirectory=C:\TEST_DIR
    form=C:\TEST_DIR\MY_NEWFORM.FMX
    Then , after stopping , starting your OC4J instance..... you call that as (in a button , for example):
    web.show_document('http:<your_server>:<port>/forms/frmservlet?config=[TEST]',_blank);
    I have not tested it.....
    Regards,
    Simon

  • How to pass the data from web dynpro to workflow.

    hi gurus,
    how to pass the data from web dynpro to workflow.
    Regards
    vijay

    Hi
    you can use function module
    data   ls_input_container  TYPE swr_cont.
    data   lt_input_container  TYPE TABLE OF  swr_cont.
    CALL FUNCTION 'SAP_WAPI_START_WORKFLOW'
        EXPORTING
          task            = ptask
        IMPORTING
          return_code     = lv_return_code
          new_status      = lv_new_status
        TABLES
          input_container = pinput_container
          message_lines   = lt_message_lines
          message_struct  = lt_message_struct.
    where you pass the data in imnternal table "pinput_container" as
      ls_input_container-element = 'KUNNR'.
      ls_input_container-value = ls_skna1-kunnr ."wd_this->lv_kunnr.
      APPEND ls_input_container TO lt_input_container .
      ls_input_container-element = 'CLUSER'.
      ls_input_container-value = lv_cluser.
      APPEND ls_input_container TO lt_input_container .
      ls_input_container-element = 'BUKRS'.
      ls_input_container-value = lv_bukrs. " youe value as per requirement.
      APPEND ls_input_container TO lt_input_container .
      ls_input_container-element = 'VKORG'.
      ls_input_container-value = ls_sknvv-vkorg. " youe value as per requirement
      APPEND ls_input_container TO lt_input_container .
      ls_input_container-element = 'VTWEG'.
      ls_input_container-value = ls_sknvv-vtweg. "youe value as per requirement.
      APPEND ls_input_container TO lt_input_container .
      ls_input_container-element = 'SPART'.
      ls_input_container-value = ls_sknvv-spart. "youe value as per requirement.
      APPEND ls_input_container TO lt_input_container .
    *Also Forgot to mention where ptask is your workflow ID *
    Regards,
    Arvind
    Edited by: Arvind Patel on May 14, 2010 7:38 AM

  • Calling adobe form from Web Dynpro ABAP

    Hi Friends,
                        This is the following error, which i got when i tested my application. Calling adobe form from Web Dynpro ABAP.
      WebDynpro Exception: ADS: Request start time: Tue Nov 16 14:00:22 YEKT
      2010(200,101).
                        Can some one tell me how to solve this....
    Regards
    Sankar

    Hi,
    Please refer to this same link in forum
    WebDynpro Exception: ADS: Request start time, start Interactive Form
    WebDynpro Exception: ADS: Request start time
    Thanks
    Pradeep

  • Regarding how to pass the data from web dynpro to workflow

    hi gurus,
    how to pass the data from web dynpro to workflow.
    Regards
    vijay

    Check this [thread|SAP_WAPI_START_WORKFLOW;

  • Calling Batch input from Web Dynpro - any alternatives for table updates?

    Hi!
    I am asked to create a screen in Web Dynpro for the GJ30 transaction (JV Cutback mapping of WBS' elements). I created a remote enabled function module which call batch input for GJ30 . Testing the Function modules direclty goes fine, but not calling the function module from WD. then I get the same error message as when I once tried to call SAP GUI from Web Dynpro ( Call transaction /submit program).
    My next step is to try to create a batch input session (instead of call transaction) and run it using rsbdcsub, and then check the result of the run. But maybe this will fail of the same reason as well, and I suppose this will make the user waiting longer for the response .
    I read somewhere that Web Dynpro does not support batch Input. But what can you do when there are no standard BAPI's for the update you want to do in SAP ?  We are not supposed to do direct table updates.  
    Anyone who have struggled with the same issues and found a solution??
    regards, Tine

    Hi,
    as BDC is calling screens and in Webdynpro ABAP you cannot use SAP GUI sceeen, you are getting short dump.
    Refer CNTL_SYSTEM_ERROR in webservices from r/3 system
    Thanks,
    Chandra

  • CAF DB Update for CAF Entity Service from Web Dynpro

    Hi all,
    I have created an entity service in CAF called “Contacts’ which contains the following attributes.
    phoneNo
    cellNo
    emailID.
    Another entity service called "Person" is created. This contains the following attributes.
    personId
    personName
    personAddr
    contactsRef. (Cardinality -> 0..n , Relational Type -> Composition)
    That means Contacts entity service is used within Person entity service. Now it is working fine within CAF service browser. Now the Web Dynpro DC of CAF application is used within another custom Web Dynpro DC project. I want to store data from Web Dynpro.
    Within the context of component controller of  Web Dynpro the structure is like
    APerson
         |_ personId
         |_ personName
         |_ personAddr
         |_ contactsRef       
                    |_ phoneNo (Under contactsRef)
                    |_ cellNo (Under contactsRef)
                    |_ emailID (Under contactsRef)
    So I have written the following code within web dynpro custom method.
    APerson person = PersonServiceProxy.create();
    java.util.List ls = new ArrayList();
    for(int i=0; i<4;i++)
    AContacts contact = ContactsServiceProxy.create();
    contact.setCellNo("9092130156");
    contact.setEmailID("[email protected]");
    contact.setPhoneNo("432258");
    contact.getAspect().sendChanges();
    ls.add(contact);
    person.setRelatedModelObjects("contactsRef",ls);
    person.setPersonID("9999");
    person.setPersonName("xyz");
    person.setPersonAddr("ABC, KOL");
    wdContext.nodeAPerson().bind(person);
    person.getAspect().sendChanges();
    CAFServiceFactory.getServiceFacade(idendityDefinition.class);
    After saving the data from Web Dynpro I am trying to test it from CAF service browser. But I am getting only the parent row. I mean only the value of personId, personName and personAddr fields which I have stored from Web Dynpro. But no value is coming within the table for Contacts entity service for composition relation.
    Could anybody help me how can I solve my problem?
    Thanks & Regards
    Chandan
    Message was edited by:
            Chandan Jash

    Hi Chandan,
    Can you do person.getRelatedModelObjects() and get the contact object, to check whether it is null, also check in the CAF DB whether the data you entered is present.
      I am not sure the code is actually adding the contact model object to person.
    Go thru this SDN Blog on usage of the CMI API's, there is a link for CMI documentation in it which might help you get the right code for adding the contact object.
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/cef4f43e-0d01-0010-db84-ede25c874115.
    award points if  info is helpful
    Regards,
    Anish

  • Authorization error calling a XI web service from Web Dynpro

    Hi all,
    I'm trying to communicate to XI from a Web Dynpro application but I get an Unauthorization error (401).
    I've generated a WSDL in XI and import it to web dynpro as a new Model. But when a I call the web service, the exception "Service call exception; nested exception is: com.sap.engine.services.webservices.jaxrpc.exceptions.InvalidResponseCodeException: Invalid Response Code: (401) Unauthorized." appears.
    I don't know how to pass the right user and password from Web Dynpro, I've tried the web service from SOAP client tools and it works fine.
    I'll apreciate any help.
    Regards,
    Diego.

    Hola mi  nombre es Luis,
    Creyendo que eres español te escribo en tal idioma.
    He visto que a ti también te devolvía un error de autentificación 401, y que lo subsanaste, pero a mi con la solución que te dieron no me vale, ya que implemento el código que te ofrecieron para arreglarlo y ahora me da un fallo de "Server Error" poniendo en usuario y password, los correspondientes a XI.
    +Request_MI_outTurnoverDetailsDisplay_MI_outTurnoverDetailsDisplay req=new Request_MI_outTurnoverDetailsDisplay_MI_outTurnoverDetailsDisplay();
    wdContext.nodeRequest_MI_outTurnoverDetailsDisplay_MI_outTurnoverDetailsDisplay().bind(req);
    req._setUser("username");
    req._setPassword("password");+
    No sé si es que ese usuario y contraseña son otros distintos.
    Si pudieras ayudarme, te lo agradecería.
    Un saludo, Luis

  • What is best practice for calling XI Services with Web Dynpro-Java?

    We are trying to expose XI services to Web Dynpro via "Web Services".  Our XI developers have successfully generated the WSDL file(s) for their XI services and handed off to the Web Dynpro developers.
    The Java developers put the WSDL file to their local PC's and import as "Adaptive Web Services" data models.  When the application is constructed and deployed to our development box, the application abends because the J2EE server on that box cannot locate the WSDL file at runtime (it was on the developers box at, say, "C:\temp\" and that directory does not exist on the dev server).
    Since XI does not have a way of directly associating the generated WSDL file to the XI service, where is the best place to put the WSDL so it is readable at design time and at run time?  Also, how do we reconcile that we'll have 3 WSDL files for each service (one for Dev, one for QA and one for Prod) and how is the model in Web Dynpro configured so it gets the right ome?
    Does anyone have any good guide on how to do this?  Have found plenty of "how to consume a Web Service in Web Dynpro" docs on SDN, but these XI services are not really traditional Web Services so the instructions break down when it comes time to deploy.

    HI Bob,
    As sometimes when you create a model using a local wsdl file then instead of refering to URL mentioned in wsdl file it refers to say, "C:\temp" folder from where you picked up that file. you can check target address of logical port. Due to this when you deploy application on server it try to search it in "c:\temp" path instead of it path specified at soap:address location in wsdl file.
    Best way is  re-import your Adaptive Web Services model using the URL specified in wsdl file as soap:address location.
    like http://<IP>:<PORT>/XISOAPAdapter/MessageServlet?channel<xirequest>
    or you can ask you XI developer to give url for webservice and username password of server

  • How to Expose CAF services as web services?

    Hi friends,
    I want to expose my CAF entity services and application services as web services.
    Can I do that, if yes How?
    In NWDS While designing the application service I have found two options in the <b>General</b> tab:
    1) Remote Enabled Service    [I am able to select it]
    2) Web Service Enabled        [I am not able to select it]
    What is the significance of each
    Also I am able to check first option but second option is disabled in my NWDS,
    Can you guide me how can do that?
    Thanks in advance for your time,
    Deepak

    Hi Deepak,
    Please have a look at this tutorial written by Austin:
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/5e9ca25b-0e01-0010-bbaa-f3b963e89edd
    in there is a kind of step by step solution how to enable your application service as web service.
    I am not sure if you can expose a entity service as a ws. The only way i know is mapping to an application service.
    I hope this helps..
    best regards,
    rene

Maybe you are looking for