Skip to Content
I have come across situations where portal iView has to be launched from java iView. The following technique can be used to launch an iView based on PCD object from another Java iView.   Step 1:  Obtain the Portal Component URI  IPortalComponentURI portalCompURI = componentRequest.createPortalComponentURI();  Step 2: Specify the PCD location of the object  String pcdLocation=”pcd://portal_content/….”;     Step 3: Provide “End user permission” for your users (based on role/group/users) target PCD object. This can be done by editing the target PCD object.  Step 4: Set the context of portal component URI object and obtain the URL.  portalCompURI.setContextName(pcdLocation);  s_Url =   portalCompURI.toString();       Note: This technique can be used to replace old URL generator service One example is to generate URL for Transactions as mentioned in https://www.sdn.sap.com/irj/sdn/weblogs?blog=/pub/wlg/2510. [original link is broken] [original link is broken] [original link is broken] [original link is broken] [original link is broken] [original link is broken] However same can be used to launch webdynpro or any appintegrator based iViews.
To report this post you need to login first.

6 Comments

You must be Logged on to comment or reply to a post.

  1. Former Member
    Hi Arul,
    I have the same requirement. I have to call one pcd iview in java iview. I am new to development side. I ve created one jspdynpage and i ve written ur code there, wat else i ve to write to call that pcd iview ?

    regards
    Amit

    (0) 
    1. Former Member Post author
      You don’t have to write anything more.Make sure the at the PCD location of the target iView is correct. Just deploy your par file and either preview or create an iView.

      (0) 
      1. Former Member
        Hi Arul,

        I have written the code before doinitialization. It is showing syntax error in following line

        portalCompURI.setContextName(pcdLocation);

        can u plz tell me the reason.

        regards

        (0) 
  2. Former Member
    Hi,

    This is my code:
    public class UserInstructions extends AbstractPortalComponent
    {
        public void doContent(IPortalComponentRequest request, IPortalComponentResponse response)
        {
         IPortalComponentURI portalCompURI = request.createPortalComponentURI();
         String pcdLocation = “pcd:portal_content/AWMASN/goog”;
         portalCompURI.setContextName(pcdLocation);
        }
    }

    I am trying to invoke the iview “pcd:portal_content/AWMASN/goog” from this component. When I run preview UserInstructions component, it just opens a blank page and no error. Should I do anything to invoke the iview?

    Thanks, VP

    (0) 
    1. Former Member Post author
      The piece of code given above only creates a URL . To create a URL , you need to add another line String url=portalCompURI.toString(); and use this generated URL in the javascript window.open(); or use this URL in the JSPDYNPage to redirect the jspdynpage to this new URL
      (0) 

Leave a Reply