How to acces portal services in webdynpro

Hi I want to access portal services from webdynpro,  i red that for that we have to  provide sharing reference in webdynpro application. which will be
PORTAL :< Vendor name>/<Full qualified name of the portal service>
my question is how to find out vendor name and Full qualified name of the portal service from par

Hi,
Web Dynpro applications can access portal services in one of the following ways:
●      Directly: The application can get an instance of the service on the machine on which the Web Dynpro application is running.
●      Via the Service Factory: The application can request an instance of the service from the service factory. The service factory provides a conduit to portal services to ensure that the proper service is called, even in cases when the Web Dynpro application and the portal are running on different machines.
Only services written in a remote-safe manner are available via the service factory. These services include the following portal services:
Page Service
Tray Service
Page Service
The page service provides information about the page in which the application is running, and enables you to perform the following tasks:
●      Getting a list of the atomic names of the visible iViews in the page.
You may want to use this method to avoid updating the user interface of an iView when it is not visible.
IWDPageService pageService = (IWDPageService)
    WDPortalUtils.getService(WDPortalServiceType.PAGE_SERVICE);
// String array receives iView names
String[] iViews = pageService.getVisibleIViews();
●      Hiding/showing iViews in the page
IWDPageService pageService = (IWDPageService)
    WDPortalUtils.getService(WDPortalServiceType.PAGE_SERVICE);
// display iView Search
pageService.showIView("Search");
// hide iView Details
pageService.hideIView("Details");
Changes to the visibility of iViews are not saved. When a user refreshes the page, the original settings are restored.
Tray Service
The tray service enables you to add a menu item to an iView or page tray, and to specify a Web Dynpro action to execute when the menu item is selected.
The following is an example of adding an iView and page menu item:
IWDTrayService trayService = (IWDTrayService)
    WDPortalUtils.getService(WDPortalServiceType.TRAY_SERVICE);
if (trayService != null) {
    // Add iView tray menu item
    trayService.addIViewItem("addItemComment", "Add Comment",
    wdThis.wdGetAddItemCommentAction(), null);
    // Add page tray menu item
    trayService.addPageItem("addItemComment", "Add Comment",
    wdThis.wdGetAddItemCommentAction(), null);
Generally, tray menu items are added in the wdDoModifyView() method. Make sure to add the menu item once; otherwise, duplicate menu items are displayed.
Procedure
This section describes how to call a portal service.
For services whose interfaces are provided by Web Dynpro (such as IWDPageService and IWDTrayService), you do not need to perform Steps 1 and 2.
       1.      Make a sharing reference to the service, by doing the following:
                            a.      Right-click the Web Dynpro development component or Web Dynpro project, and select Properties.
The Properties dialog box opens.
                            b.      From the left pane, select Web Dynpro References.
                            c.      In the Sharing references tab, add a reference to the portal service with the following format:
PORTAL:<Vendor name>/<Fully qualified name of the portal service application>
For example, the following shows a reference to the navigation service:
This graphic is explained in the accompanying text
       2.      To build the project, add the JAR file containing the service to the classpath of the project in the IDE.
Do not store the JAR file of the service in the libfolder of your development component or Eclipse project. This causes classloader problems at runtime.
       3.      Get an instance of the service.
To call a portal service directly, without the service factory, call WDPortalUtils.getServiceReference() with the key for the service, as in the following example:
IUserObjectBasedNavigation obnService = (IUserObjectBasedNavigation)
    WDPortalUtils.getServiceReference(IUserObjectBasedNavigation.KEY);
To call a portal service via the service factory, call WDPortalUtils.getService() with the WDPortalServiceType constant for the service, as in the following example:
INavigationService navService = (INavigationService)
    WDPortalUtils.getService(WDPortalServiceType.NAVIGATION)
If more than one Web Dynpro controller needs to use the same portal service, you can store the portal service reference in a controller context node. All other controllers that need to use the service must define a context node and map it to the context node with the service reference.
A portal service can be called only when the portal platform and the Web Dynpro application are running on the same machine.
It is recommended not to use your Web Dynpro-based portal content in a global or federated portal scenario.
Refer This Link for More Information:
[http://help.sap.com/saphelp_nw04s/helpdata/en/d2/0357425e060d53e10000000a155106/frameset.htm]
I Hope This Information Might Be Helpful For you.
Regards,
Sharma.

Similar Messages

  • How to accessing portal services

    Hi All
             I am saravanan. i have doubts. Can u plz solve my doubts?.
    1). How to Accessing Portal Services from a Webdynpro application?.
    2). Portal Eventing with Webdynpro and other Applications?.
    3). single signon from Webdynpro applications?.
         These are my doubts. Could u plz solve my problem.
    If u have any material or PPT or PDF files kindly send my mail.
    This is my mail id : [email protected]
    Thanking You
    Saravanan

    Hi Swathi
    I'm trying to do exactly the same, i have a webdynpro application and i'm trying to access KM libraries to get the full list of metadata properties. But i'm getting and error while trying to get the service on the following code:
    Property propertyAux = null;
    IResourceFactory resFactory = ResourceFactory.getInstance();
    IRepositoryServiceFactory serFactory = resFactory.getServiceFactory();
    IPropertyConfigurationService propConfigService = (IPropertyConfigurationService) serFactory.getService("PropertyConfigurationService");
    IMetaNameListIterator i = propConfigService.getMetaModel().nameIterator();
         while (i.hasNext()) {
         IMetaName metaname = i.next();
         if ( metaname.getDocumentPatterns()!= null){
         propertyData.setId(metaname.getName());
         propertyData.setName(metaname.getLabel(locale));
         propertyData.setNamespace(metaname.getNamespace());
         propertyData.setDescription(metaname.getDescription(locale));
         propertyList.add(propertyData);
    The error on the trace is this one:
    System.err#sap.com/KmmsListEAR#System.err#Guest#2####30a27fa0cbfa11dbace30018de0545f1#SAPEngine_Application_Thread[impl:3]_29##0#0#Error##Plain###Configuration Framework error: unable to create an IConfigClientContext instance from an EP5 userInitialConfigException: The configuration service locator could not be initialized for any of the environments. The configuration framework is not available.#
    System.err#sap.com/KmmsListEAR#System.err#Guest#2####30a27fa0cbfa11dbace30018de0545f1#SAPEngine_Application_Thread[impl:3]_29##0#0#Error##Plain###InitialConfigException: The configuration service locator could not be initialized for any of the environments. The configuration framework is not available.
    Could you please give me a hand on this one?
    Thanks in advance

  • Portal Service and WebDynpro

    I have follow the [pdf|https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/7e7ecd90-0201-0010-4195-a134a5653fc1] guide to make a portal Service and integrate it into a webDynpro.
    I made a simple portal service, made the par file and upload to the portal.... then i did all what the guide said, and deploy the web Dynpro, when I run it i get an error java.lang.NoClassDefFoundError: com/test/IPingService ..... On the project of my web Dynpro I put the jar file of the service just in the Build Path, not in the lib folder, cause in the server its supposed to be the class published like a service.
    How do the webDynpro see the Class of my Service?
    The Sharing Reference its the key?
    The portal service its running only to upload the Par?
    There its a way to check its the portal service its running properly on the portal?
    My portalapp on the portalService have this
    <service name="PingService">
          <service-config>
            <property name="className" value="com.test.PingService"/>
            <property name="startup" value="true"/>
            <property name="SafetyLevel" value="no_safety"/>
            <property name="vendor" value="com.test"/>
          </service-config>
    And my SharingReference on the WebDynpro is
    PORTAL:com.test/com.testPingService
    My code on the WebDynpro is:
    IPingService pingService = (IPingService) WDPortalUtils.getServiceReference(IPingService.KEY);
        wdThis.wdGetContext().currentContextElement().setMsj(pingService.ping());
    And all that i get its:
    java.lang.NoClassDefFoundError: com/test/IPingService

    Dear José,
    Before you add the WDPortalUtils jar file, modify your portalapp.xlm adding the follow line:
    tag, replace sap.com for your vendor
    When you compile the par file, rename it no com.test (4 example) PingService.par
    In your WDJ project, add the follow shring reference PORTAL:vendor/full par filename, excluding the extension.
    Thanks and Regards,

  • How to Create Portal Service in Portal 7.3

    Dear Experts,
    how to create the Portal Service in Portal 7.3, as we create in Portal 7.0 by creating the Portal Project in that we create Portal Service and we can start and stop in Portal Service configuration in System Administration
    Thanks,
    Sagar Pande

    Hi Sagar,
    Procedure
      1.  Open the SAP NetWeaver Administrator by either of the following methods:
           a. Use the URL to your AS Java (hostname:port) to access the AS Java home page and use the link to SAP NetWeaver Administrator.
           b. Alternatively, add nwa to the AS Java URL to access SAP NetWeaver Administrator directly. (hostname:port/nwa).
      2  Go to   Operations Management   Systems   and click the Start & Stop link.
        The Start & Stop: Java EE Instances window opens.
      3  Click the Java EE Application bar and select the relevant application in the Application List.
        The Portal Services pane displays the services associated with the selected application.
      4  Use the buttons Start Service or Stop Service.
    Refer to Portal 7.3 help
    http://help.sap.com/saphelp_nw73/helpdata/en/f6/ac978061ac4b24a87a1f821313c4fe/frameset.htm
    Br,
    Venky

  • How to check adobe services in webdynpro

    I am trying to create adobe form but when I click on 'layout' tab geting following error:
    'The forms design tool for developing the form layout could not be started; either it is not installed or there are errors in the installation'
    where to check whether adobe services are registered or not.
    thanks
    Chitrakesi

    Hi Chitra,
    To check whether ADS is installed on the system the following steps have to be considered.
    Configuration Check for PDF-Based Forms in ABAP
    Purpose
    Use this process to check whether all configuration steps for developing and processing forms in an ABAP environment are completely and to verify, which ones you still need to perform manually.
    Process Flow
    1. The first check you need to perform is Checking by Executing Test Report FP_TEST_00
    2. Check the ABAP Connection
    3. Check the User and Password
    4. Check the Destination Service
    Step 1.
    Procedure
    1. Log on to your SAP NetWeaver AS ABAP.
    2. Call transaction SA38 and enter the name FP_TEST_00.
    3. Choose Execute (F8). A dialog box is displayed.
    4. Enter FP_TEST_00 in the field Form.
    This is displayed as the default form name.
    ADS5. Enter the name of the connection to the ADS. Enter the default name , or, if you have specified another name, the one you are using in your system.
    6. In the dialog box, choose Output in Print Preview.
    7. Enter an appropriate device type in the field Output Device.
    8. Choose Print Preview.
    Result
    If the configuration is correct, a form containing several lines on two pages is displayed.
    If the configuration is not correct, no form is displayed. In that case, you need to perform further tests.
    Step2.
    Checking the ABAP Connection
    Use
    This is a test for checking the RFC destination. This test applies to both connections using Basic Authentication and SSL connections.
    Procedure
    1. Log on to your SAP system.
    2. Call transaction SA38.
    FP_PDF_TEST_OO. 3. Enter the name of the test report
    4. Enter the name of the connection. Enter the default name ADS, or, if you have specified another name, the one you are using in your system.
    5. Choose Execute (F8).
    Step 3.
    Checking the User and Password
    Use
    This is a test for checking whether the entries for the user, security role, and passwords are correct in a system that uses Basic Authentication.
    Procedure
    1. Enter the following URL in your Web browser: http://<server>:<port>/AdobeDocumentServices/Config<server> where is the name of the J2EE engine where the Adobe document services are installed, and <port> is the port of the J2EE engine.
    Note that the entries in the URL are case-sensitive.
    2. The Web page of the Web service AdobeDocumentServices is displayed. Choose Test.
    3. Choose rpdata(test.u2026).
    4. Choose the Send button without entering any parameters.
    5. Enter the user name and password provided in the previous configuration steps.
    6. Choose Submit.
    Step 4
    Checking the Destination Service and the ICF Service
    Use
    Use the first of the following tests for checking the settings of the destination service. If you receive any error messages, continue with the further tests listed below.
    Prerequisites
    You have already checked the ABAP connection [Page 7].
    1. Checking the Destination Service using a test report in AS ABAP
    Using this test you can check if the complete configuration of the destination service and the ICF service is correct. There are two test reports available:
    ● FP_CHECK_DESTINATION_SERVICE This report checks the configuration of the destination service and the ICF service sap/bc/fp.
    ● FP_CHECK_HTTP_DATA_TRANSFER This report checks the configuration of the destination service and the ICF service sap/bc/fpads. You only need this service, if AS ABAP and AS Java (with ADS) are installed in different systems, and you want to bundle your forms to improve performance.
    The ICF service sap/bc/fpads and the corresponding settings in the destination service are not configured during the initial installation of SAP NetWeaver 7.0. For more information, see Creating the Service User ADS_AGENT in the ABAP Environment [Page 12] and Activating the ICF service [Page 13].
    1. Log on to your SAP NetWeaver AS ABAP system.
    2. Call transaction SA38.
    3. Enter the name of the test report.
    4. Execute the test without choosing the option With Destination Service.
    5. The system renders a test form in the background without using the destination service and displays the size of the created PDF.
    6. Execute the test again. Now select the option With Destination Service.
    7. If the settings of the destination service are correct, the system displays the same message as before (see step 5).
    2. Checking the ICF Service using the Web Browser
    1. In your Web browser enter the URL
    http://<server>:<port>/sap/bc/fp/form/layout/fp_test_00.xdp
    where <server> is the server that hosts the AS ABAP and <port> is the http port of the AS ABAP.
    2. In the dialog box enter ADS_AGENT as user and the password you have specified for it.
    Regards
    Manoj Kumar

  • How to make use of Portal service in the web dynpro application

    hi
    I have some portal service and how to use that in the web dynpro application.
    and also what is the main diff between Portal Component and web dynpro application.
    do we required portal to run web dynpro application.
    thanks
    mmukesh

    Hi,
    >> I have some portal service and how to use that in the web dynpro application.
    Yes. U can use Portal service in webdynpro. Check the link given by subathra.
    >> and also what is the main diff between Portal Component and web dynpro application
    Portal Components are components designed to run in portal server while webdynpro application can run in J2EE WebAS.
    >> do we required portal to run web dynpro application.
    No for general cases. Just WebAS is sufficient to run webdynpro appl. But if u use portal service in ur webdynpro appl, then make sure both (portal service and webdynpro appl) run on same J2EE engine. That is mandatory.
    Regards,
    Vijai

  • How to consume Web Service in ABAP WebDynpro

    Hi
    I want to know the entire details about how to consume Web Service in WebDynpro application.
    regards
    Piyush

    hI piyush,
    Have a look at this Blog by Thomas Jung.
    /people/thomas.jung/blog/2007/12/17/consuming-services-with-abap
    on consuming webservies thru webdynpro ABAP
    Cheers
    Mary

  • How to consume UME API in webdynpro applications

    Hi ,
    i want to consume the portal services in webdynpro applications.
    here i want to  use UME Service .
    how to consume it my WD applications .
    isit  the same way as described in the below link : [http://help.sap.com/saphelp_nw70/helpdata/en/d2/0357425e060d53e10000000a155106/content.htm]
    Regards,
    Govindu

    Yep, the http://help.sap.com/saphelp_nw70/helpdata/en/d2/0357425e060d53e10000000a155106/content.htm shows how to establish a reference to a portal service in order to consume it in your application. But it works only if you have the API of the portal service you want to reference.
    BR, Siarhei

  • What is Portal Service?

    Hi All,
           I want to use Portal Service in my WebDynpro Application. I don't know any thing about this. Can any body please give me some info about what is portal service and how to use Portal Service...
              Actually my requirement is to store data application wide. When i am searching in the forum for the same i found an useful link for this.
    Re: Application wide data
             In that Ravi Pasupathy answered for this and proposed a solution using Portal Services.
    Thanks in Advance,
    VJR.

    Hi,
    Portl services are used to integrate webdynpro app with Portal, You can access portal data or features using this portal services.
    see this
    Re: how to make use of Portal service in the web dynpro application
    Regards,
    Naga

  • Accessing portal roles in webdynpro for java

    Hi,
    Please let me know how to access portal roles in webdynpro for java.
    Rgds,
    Patana

    Hi ,
    Please use this API to access the portal roles:
    IRoleFactory fact=UMFactory.getRoleFactory();
    Also see this code to get more information of role using code:
    IRoleFactory rolef=UMFactory.getRoleFactory();
    IRoleSearchFilter searchfilterrole= rolef.getRoleSearchFilter();
    ISearchResult searchResult = rolef.searchRoles(searchfilterrole);
    while(searchResult.hasNext())
    String unq=(String) searchResult.next();
    IRole role1=rolef.getRole(unq);
    String roleName = role1.getDisplayName();
    String roleID = role1.getUniqueID();
    // Once you get the informationof role you can use it in your application as per your requirement.
    Also please note that:
    You should add "com.sap.security.api.jar" to your project`s java build path for getting the Portal Security API's.
    I hope this solves the problem. Please revert back incase you need any further informationon this.
    Thanks and Regards,
    Pravesh

  • Portal service as webservice?

    hi,
    How to expose portal service as webservice? Any template kind of thing to achieve it?
    Regards,
    S R

    hi,
    See this documentation
    http://help.sap.com/saphelp_nw04/helpdata/en/f0/581140d72dc442e10000000a1550b0/frameset.htm
    Regards,
    Ganesh N

  • Convert portal service to web service option in NWDS

    Hi all,
    I am using SAP NetWeaver Developer Studio (Version: 7.0.14), in this I couldn't find option to convert portal service to web service.
    Please help me out, how to convert portal service to web service through NWDS or any other way to do it.
    Helpful answer will appreciate.
    Thanks,
    Regards,
    Kathiresan R

    Hi
    In NWDS go to New ->other -> portal application -> portal application object -> portal web services -> portal web services from portal services and select ur portal service.
    Generate portal web service with PDK wizard by choosing Portal web service from portal service
    Select the interfaces by clicking the browser button.
    select the methods to be exposed to web service.
    Now WSDL files are generated for portal services.
    You can view the WSDL by going to
    System administration->support->portal runtime -> soap admin -> web services.
    Hope this works for you. Please excuse any small mistakes if I have made.
    Regards,
    Shitij

  • Calling Webdynpro from a Portal service

    Hi,
    I am new to EP. I have a task where i have to write a Portal service which has to call a prewritten Webdynpro. Can someone guide me as to how I can call WebDynpros from Portal services.
    Thanks,
    Sudhir

    Hi Sudhir,
    That makes no sense. Portal Services are "faceless components", i.e. they have no user interface. WD is just all about UI. How should that kind of integration work / make sense?!?!
    Hope it helps nevertheless
    Detlev

  • How to log exceptions and imp logging info in Portal Service via ILogger?

    Hi Experts,
    I m trying to use ILogger for my application.
    Information about my application:
    I have created a Portal Service and exposed it as a Web Service which is deployed as a PAR file on to the SAP J2EE Engine.
    I need to use the Logging facility of ILogger in this Portal Service.
    I have written the following code in the Init() function of the Portal Service
    public void init(IServiceContext serviceContext)
           mm_logger = serviceContext.getLogger("com.persistent.pankaj");
    I have put the logger.xml in the logger folder of PORTAL-INF
    my logger.xml is as follows:
    <Server>
    <Logger name="testLog" loggerInterface="com.sapportals.portal.prt.logger.ILogger" locationName="com.sap.portal.testLog" pattern="%d # %20t %15s %m #" isActive="true">
    <LoggerClass className="com.sapportals.portal.prt.logger.SimpleFileLogger" level="INFO">
    <param filename="logs/com.persistent.pankaj.log" append="true">
    </param>
    </LoggerClass>
    </Logger>
    </Server>
    On deploying my portal service as a web service
    I m unable to get the logs.
    I even dont know where will i get the log file, means wat is the exact location where i can check my log results
    I m a newbie for this
    Please help me out
    Help will be rewarded n appreciated
    -pankaj

    Hi Pankaj,
    In your init method try this code to create the logger:
    ILogger logger = PortalRuntime.getLogger("testLog");
    In your logger.xml the logger name was testLog and not com.persistent.pankaj so while creating logger you should use testLog in the above code.
    By default all the logs are written to defaultTrace.log files, to check them read this:
    Portal Runtime Logs
    If you want to log in a seperate logfile then you should set a seperate log destination, which is not recommended on productive systems due to performance problems.
    Also read these to know how to set seperate log destinations:
    Netweaver Portal Log Configuration & Viewing (Part 3)
    Netweaver Portal Log Configuration & Viewing (Part 1)
    Netweaver Portal Log Configuration & Viewing (Part 2)
    Regards,
    Praveen Gudapati

  • How to get password of a logged in portal user in webdynpro.

    hi,
    i want to get the password of the logged in portal user through webdynpro. i already know how to get the user id and other information through webdynpro (using WDClientUser), but i want to get the password as well.
    this is an urgent requirement. Immediate help will be highly appreciated and points will be awarded for helpful answer.
    thanks in advance.

    Hi
    User Management APIs don't give the liberity to obtain the password, instead you can verify a password. Please check if your requrirement can be modified to check for password.
    Please use code mentioned below and the one suggested before.
    loggedInUser = WDClientUser.getCurrentUser();
    user = loggedInUser.getSAPUser();
    if (user != null)
    IUserAccount[] acct = user.getUserAccounts();
    if(acct[0] != null)
    b = acct[0].checkPassword(password);
    Thanks
    Srikant

Maybe you are looking for

  • Calendar Month View, Scrolling

    In Mavericks, calendar month view, trackpad scrolling works but mousewheel doesn't.  Any solution?

  • Add key fields for FM REUSE_ALV_HIERSEQ_LIST_DISPLAY

    Hi everyone, I would like to ask if it is possible or is there a way to increase the number of key fields used in FM REUSE_ALV_HIERSEQ_LIST_DISPLAY. The table parameter for the key fields is IS_KEYINFO. It can only contain 5 key fields. My program ne

  • Pb 12" 1.3 GHz sleep issues

    To any and all that may advise: pb 12" 1.3 GHz 512 MB OS 10.4.2 Recently my pb has been having intermittent sleep issues. I have tried resetting the power manager, and this has not resolved this issue. AHT gives all green lights for hardware operatio

  • Photos in some emails don't display they will with live mail

    Some emails don't download photos and these photos don't come as attachments they are part of the original email. I checked that the photos have been sent in live mail which i want to move away from.It has not happened a lot. I can see no difference

  • Error when sending photos from iPhoto 08 (send to e-mail button)......

    When I go to e-mail pictures from iPhoto 08 I get the following message (the e-mail is correctly created though), any suggestions on what to fix / look at? Mail got an error: AppleEvent handler failed http://discussions.apple.com/thread.jspa?threadID