Read Portal iViews with a webservice

Hi,
I need to get all the iViews related to all roles assigned to a requested user.
My webservice now does the following:
try{
     String[] roles =UMFactory.getRoleFactory().getRolesOfUser("USER.R3_DATASOURCE."+user,true);
for(int i=0;i<roles.length;i++){     
     IRole role = UMFactory.getRoleFactory().getRole(roles<i>);
        Userroles<i>= new String(role.getUniqueName());
}catch(Exception e1){
I tried with  javax.naming.directory.DirContext but it don't seems to work. Is it possible to do so with a webservice?
Many thanks
Antoni Macià

If you are looking for an example on web service using security, following link has one sample
http://otn.oracle.com/sample_code/tech/java/web_services/content.html
Chandar

Similar Messages

  • Read Portal IViews

    Hi,
    I am new to using portal.I have been trying to use JNDI lookup to read portal iviews using
    standalone java with relevant jars but i get javax.naming.NoInitialContextException: Cannot
    instantiate class: java.naming.factory.initial.Please anyone help me out with jndi name and
    the ways i have to implement.Here is the code..
    env.put(Context.INITIAL_CONTEXT_FACTORY,
              "com.sapportals.portal.pcd.gl.PcdInitialContextFactory");
    //"java.naming.factory.initial"
              env.put(Context.PROVIDER_URL,                                    
    "localhost:53000");
              env.put(Constants.REQUESTED_ASPECT, PcmConstants.ASPECT_SEMANTICS);          
    env.put(Context.SECURITY_PRINCIPAL,                     "administrator");
    javax.naming.InitialContext ctx;
    ctx = new InitialContext(env);
    Thanks,
    Sucharitha

    Hi Kiran,
    You have been using this link as URL.
    http://<host>:<port>/irj/portal?NavigationTarget=
    ROLES://portal_content/com.sap.pct/
    platform_add_ons/com.sap.caf.eu.gp.folders.gp/com.sap.caf.eu.gp.roles.runtime/
    com.sap.caf.eu.gp.worksets.runtime/com.sap.caf.eu.gp.pages.procinstance&DynamicParameter=
    processId%3704process.template.id=704B8100BCC111DEC2C300096B6E4F29&param1=CPD&NUMBER=
    4500001186&UserId=138458&&taskId=
    Now just try replacing following characters between occurence of "ROLES" and "&DynamicParameter" as follows:
    :  --> %3A
    /  --> %2F
    Also, after "&DynamicParameter" replace
    = --> %3D
    & --> %26
    to define passed Parameter Names and Values.
    It will look something like this:-
    "http://<host>:<port>/irj/portal?NavigationTarget=
    + "ROLES%3A%2F%2Fportal_content%2FXYZContent%2FBHBSS%2FXYZPages%2FXYZMaintenance" +
    %2FpgXYZ&DynamicParameter="
    + "RF02D-VKORG"+"%3D" + "1040"
    + "%26" + "RF02D-KUNNR" + "%3D" + 40
    + "&CurrentWindowId=WID1232176120474&NavMode=3"
    I have show the URL in the form of strings appended, you need to show them in a flow removing the double quotes and plus symbol.
    Let me know if you still have problem accessing through the link.
    Regards,
    Tushar Sinha

  • Creation of Portal iview, with BSP on internal server, call portal external

    Hi all,
    folowing issue:
    we have a test portal link with the internet via apache reverse proxy:
    e.g. http://www.xxx.at/irj   is linked with http://cscinternal.csc.com:51000/irj
    The portal can be started without any problem.
    further we have a bsp applikation on an other internal SAP Server which can be reached with
    http://cscinternal02.csc.com:8047.
    the server is also listed in the apache reverseproxy list as   http://www.xxx.at/its
    The bsp application link: http://www.xxx.at/its/sap/bc/bsp/sap/y_test_pdf_01/main.htm
    can be reach via internet without any problem.
    The bsp shows an radiobutton list + button, with the button one can show a list in an second window.
    so, now i will call this bsp in an iview via portal
    01. i tried the "URL iview", result: i can reach the html but on any action the side do nothing
    02. i tried to config "iview BSP" BUT .... i have now idea what system i should put in,
         the second sap system is configured but there is the internal name in (i guess) ...
    so i'm  newbee in portal things, so i don't know where i can configure a system ...,
    BUT beside this, PLEASE can anyone describe me how i can manage this internal BSP
    in the portal to call it from external?
    thanks a lot
    bye Mike

    Hi Mike,
    Try below steps to make sure your have proper  connection between Portal and  back end SAP system.
    1) Create  a system object , Enter required details for "Web Application Server" Properties with below two options
              A) Enter Direct SAP Server details
              Web AS Host Name : cscinternal02.csc.com:8047
              Web AS Path: /its/sap/bc/bsp/sap
              Web AS Protocol: http
             B) Enter apache reverseproxy
              Web AS Host Name : www.xxx.at/its
              Web AS Path:/sap/bc/bsp/sap
              Web AS Protocol: http
    2) Create  a  Alias  .  Run the connection test for Web Application Server (WAS). Make  sure  connection tests are successfull
    3) Create a  BSP Iview ,
      BSP Definition Type:  Application
      Selct System Alias
      Customer Namespace: sap
      Application NameSpace: sap
      Business Server Page (BSP) Application:  y_test_pdf_01
      Start Page: main.htm
    Let me know if  it works.
    Thanks
    Aravind
    Intelligroup

  • How to add Portal iViews with Web Page Composer

    Hi,
    We are working with Web Page Composer in EP7.0 SP13.
    We are creating web pages and we would need to add Portal iViews into. When we try to add an iView, we cannot select it from Web Content Browser to drop into the web page container.
    How can we add iViews into our web pages?
    Helpful answers will be rewarded!!
    Thanks in advance,
    Samantha.

    Hi,
    See these:
    [http://help.sap.com/saphelp_nw70/helpdata/en/06/4776399abf4b73945acb8fb4f41473/frameset.htm]
    [/message/4414263#4414263 [original link is broken];
    Best regards,
    Avishai Zamir

  • In Portal , iView of type WebService Not working.

    hi all ,
    I am working on O4s SP7,
    I am trying an example where i want to access a web service using EP.
    i have made the proxy settings that are required..
    In system configuration , under Visual Composer i created a new Model from System Template of type Web Serice and gave the below url
    <a href="http://www.webservicex.net/ConvertTemperature.asmx?WSDL">http://www.webservicex.net/ConvertTemperature.asmx?WSDL</a>
    I gave User Mapping Type as admin,user.
    then when i test it it says,
    Retrieval of default alias successful
    <b>Connection failed. Make sure user mapping is set correctly and all connection properties are correct.</b>
    Can anyone tell me what might be the reason ?
    i ignored it and gave that system an alias.
    Then i went to Content development and under VC created a new Model of type Iview, again web service one ,gave some name, used the system alias as  described  above , and when i clicked next ,
    it says <b>"Could not connect to back-end application. Check your system. The server may be down or there may be an error in a system parameter."</b>
    Has any one faced this problem earlier ?

    moved a little forward, created a system as follows.
    System Administration, syste configuration , Visual composer, models and created a new system from template of type Web Service System using WSDL URL.
    i used the followig URL
    <a href="http://www.webservicex.net/ConvertTemperature.asmx?WSDL">http://www.webservicex.net/ConvertTemperature.asmx?WSDL</a>
    However whn i test it it says....
    Retrieval of default alias successful
    <b>Connection failed. Make sure user mapping is set correctly and all connection properties are correct.</b>
    what does this mean..
    i ignored it and continued with creation of my iView and used this system Alias , <b>however these too it says
    "Could not connect to back-end application. Check your system. The server may be down or there may be an error in a system parameter "</b>
    what might be the reason..
    <b>my aim is to call a web service using this iview</b>
    please also let me know if i am moving in right direction

  • How to redirect to portal iview from a stand alone webdynpro application

    Hello,
    I need to able to navigate from a standalone webdynpro application, for which I do not want to create Portal iview, to a Portal iview with some data.
    Please let me know how can I pass the string value and how to navigate.
    Thanks,
    Vinit

    Vinit,
    You're walking in circles. There is no magic answer to this problem. Web Dynpro is not an application of communication / interface with other applications, but a presentation layer for the user.
    To perform this procedure interaction (simulating an ajax) you will need to use a middleware interface (CAF, EJBs, or any other technology that communicates directly with the Web Dynpro), or use the version 7.2 of Web Dynpro (maybe that solves their problems).
    If only the external page you need to open did not have the user interaction (just loading and returning information) you could consume it like a WebService.
    without more,
    Angelo

  • Event handling in Portal IView of JspDynpage

    Hi All,
    I have created the portal iview with jspdynpage.Can any body tell whether event handling can be performed from the portal iview which is created from the jspdynpage?
    Regards,
    V Karthi

    hi
    check this threads
      Event handling in portal through sap netweaver.
      From creation of JSP page to iView at Portal
    Thanks

  • Create new portal-user with webservice

    Hi,
    I'm trying to develop a ejb-webservice which is creating a new Portal-User.
    The webservice is working so far, I made methods like getDisplayName() which is returning the display name to a logonId and so on. All this is working. I'm using the component sap.security.api.sda for this.
    Problem: User-creation is not working. I think the problem might be, that a webservice is not authorized to create users? Or putting it in another way: Is it possible that a webservice is "logging in" at the portal, or sohehow authorizing itself?
    Thanks and regards
    Jan Hempel

    Hi Detlev,
    thanks for Your answer.
    It seems like that the problem was caused by using array-parameters in the webservice-method?!
    Strange, but after removing the array-parameter from the method it worked! Before the webservice never returned anything, not an error or anything else.
    Well, strange enough, but I can live with that.
    regards
    Jan

  • Import Support pack in Portal system with ESS & NWDI.

    Hi ,
    NW Portal system has the current support pack level of JAVA stack 11 which includes ESS business backages SAP_ESS 603 SP1, BP_ERP5***,BP_ERP5COM,BP_ERP5ESS, BP_ERP5HRA, BP_ERP5PSS 1.0 SP12. We are using NWDS for doing some customizing the ESS portal iViews configuration and transporting through NWDI tracks.
    If we are upgrading the support pack for netweaver and portal, whether the business packages and the java stack needs to be go through JSPM or through NWDI transport?
    At the same time we like to upgrade the SLD system which has only JAVA stack installed separately. What are the thing that we need to do in SLD before & after updating the support packages like CIM model, etc.
    As we are having the JAVA stack NETWEAVER 7.0,Eventhough SOLMAN mopz decides the level of SP level, but is it good to go to EHP1 or stay in the current Netweaver 7.0 Java stack and our current ECC are going to be in the Netweaver 7.0 Java.
    Thanks
    John

    John,
    If we are upgrading the support pack for netweaver and portal, whether the business packages and the java stack needs to be go through JSPM or through NWDI transport?
    JSPM only
    At the same time we like to upgrade the SLD system which has only JAVA stack installed separately. What are the thing that we need to do in SLD before & after updating the support packages like CIM model, etc.
    May be you want to trigger data push manually once from all system to make sure if everything is working fine , other than this nothing
    As we are having the JAVA stack NETWEAVER 7.0,Eventhough SOLMAN mopz decides the level of SP level, but is it good to go to EHP1 or stay in the current Netweaver 7.0 Java stack and our current ECC are going to be in the Netweaver 7.0 Java.
    Its good to go with latest , but to be in sync with ECC you can continue with 7.0.
    Regards,

  • Federated Portal solution with 2004sBI.

    Hi,
    I would like to know the limitation when using fedelated portal solution with 2004s BI. that means 2004s BI web functionalities are used via Enterprise-wide portal, diferent from portal component for BI.
    many customers who decide to implement mySAP ERP2005 solution is likely to implement 2 portal components. One is only for BI, another is for Enterprise wide portal, without considering system configuration deelpy.
    About the portal content, the following URL show the solutions.
    http://help.sap.com/saphelp_nw04s/helpdata/en/43/92dceb49fd25e5e10000000a1553f7/frameset.htm
    -Integration using a URL iView
    -Export/import
    -Global portal (federated portal)
    I think the global portal is the best.
    About the KM contents, I am now think what is the best way.
    I think by using fedelated portal solution, KM content iView and KM navigation iView can be used on the corporate wide portal.
    But I am not KM expert and now am considering how to use KM contents which is on BI's EP(KM) as same as those on Enterprise wide portal. is it possible if setting webdav on repository manager on enterprise wide portal?
    Kind reagards,
    Masaaki

    There are a lot of things to consider with KM, one repository or 2? The federated Portal will work with assigning a KM navigation iView to a Role and using remote role assignment. This would put KM on the producer portal. The other option is to setup a Remote KM Repository on the Consumer Portal that points to the producer. This way you can broadcast to the producer KM repository and see this in the Consumer Portal.
    With Collaboration Rooms, there are some limitations, such as the Room Directory doesn't work with remote URL iViews or Remote Role Assignments as it launches the URL on the consumer instead of the producer. Currently, Collaboration Rooms should be centralized on your single consumer. If you need to broadcast to it in the producer, you would have to setup a link to a remote repository...
    Therefore, if you're working with KM specifically, it all works within the framework, but you need to decide how centralized or decentralized you want your document storage, so there are a lot of project considerations on this one....
    Also, webdav works to access the KM repository both on the consumer and producer...

  • WebDynpro Abap table not rendered correctly inside portal iView

    Hi,
    I have a webDynpro Abap application with a table that contains radio buttons as table cell editors.
    When I run the application directly it looks fine, but when I run it inside a portal iView the radio button allignment changes to the top of the table cell.
    Please help.
    Kind Regards,
    Dirk Naude

    I found that this could be fixed by changing the portal theme using the theme editor, specifically changing the table cell padding property.

  • Portal Integration with JAVA ?

    Hello All,
           I've been working in the Portal for the past 1 Year.
    The work which I've done is :
    1. Creation of BSP's in SAP
    2. Create iViews in Portal accessing these BSP Applications.( BSP , IAC, URL,BW etc )
    3. Create Roles.
    Now I'm moved to one more Project which does the Portal Integration with JAVA.
    Can any one tell me what is it and how it can be done ?
    Regards,
    Deepu.K

    Hi Deepu
    You can achieve the same,please visit the following links:-
    http://help.sap.com/saphelp_nw04s/helpdata/en/d8/6ee03fc2269615e10000000a155106/frameset.htm
    http://help.sap.com/saphelp_nw04s/helpdata/en/d8/6ee03fc2269615e10000000a155106/frameset.htm
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/771fa290-0201-0010-3d93-865e66cc6d7e
    Regards
    Navneet
    Please revert incase of doubt.

  • Can't add to portal favorites with "&" in the name field

    Hi there
    Interesting problem which has been identified this morning ... it appears that certain iviews cannot be added to the portal favorites, and upon closer inspection, it appears that those iviews all have the "&" character in the name field.
    For example, we have an iview with the name of "SAA013 Summary of Sales & Gross Margin vs Approved Plan". As you can see, its quite long, so anything to save some space.
    If I remove the & and replace with "and", then I can add to portal favorites.
    Has anyone else come across this and found an alternate solution? I could probably get away with convincing the client to allow "and" to be inserted, but then there's quite a few iviews that will have to be renamed, which is a rather tedious task.
    Cheers,
    Andrew

    Hi,
    For some reason the note wasn't released.
    Now it is released.
    Its content:
    Symptoms:
    Portal Favorite doesn't work for object that contain the symbol "&" in the name.
    Keywords:
    Portal Favorite, navigation
    Reasons:
    The problem was a missing in the encoding of the name
    Solution:
    Fix in SP12 patch #4
    SP13 patch #1
    SP14 Patch #1.
    Regards,
    Tal.

  • Portal iview xml files

    Hi,
    Mayby anybody here knows where do the portal iviews xml files are saved in the server?
    Thanks.
    Promise to award points...
    Ruthie.

    HI,
    u talking about Iview's property(.xml) files? Should be inside the corresponding iview folder itself. Go to server do a search with *.xml on the folder /usr.
    Regards,
    N.

  • Portal iviews xml files

    Hi,
    Mayby anybody here knows where do the portal iviews xml files are saved in the server?
    Thanks.
    Promise to award points...
    Ruthie.

    Dear Maksim,
    I have a problem here with sap transaction iview - I opened an Oss and I was asked to send them all xml files of the iviews. As for now - I asked them where can I find it.
    Thanks for your help.
    Ruthie.

Maybe you are looking for

  • Cannot get XP to print

    Hello! I've been working all morning on getting my really weird network going Right now, I'm stuck on an issue between my old Windows XP box and my new iMac G5 (running OSX 10.5.5). Ive got the two computers networking and file sharing okay, but I ha

  • Item text in Purchasing order

    Hi all,   I have developed a smart form for Purchase order in that i am displaying header and item texts by passing text name, text object, text ID and language to include text. My problem is when i am looking in print privew for just creating docume

  • White bright light on unlocking the phone while using the touch ID

    Whenever i unlock my phone using touch finger id , a bright white light comes up on the left top corner.

  • Code example for virtual list view control

    I'm writing a client (C++) application to access an LDAP directory (that supports virtual lists), and I'm trying to make use of the virtual list view control to "page" my results. However, I'm having trouble getting the code to work correctly. Can an

  • Iso/ansi sql-99 query

    hi.. i'm new for oracle .. i hav one doubt .. what is the difference between normal join and iso/ansi sql-99 joins... is any advantage .. query e.g: SELECT c.course_name, c.period, e.student_name FROM course c, enrollment e WHERE c.course_name = e.co