Need to access R3 using IConnectorServiceGateway from portal service.

Hi everyone,
I need to access R3 using IConnectorServiceGateway from portal service but unable to access so as I don't get the IPortalComponentRequest. Can anyone help me out on how should i do the connection ?
Please let me know as soon as possible.
Thanks
Ritu

Hello.
I think this should work
    * Méthode renvoyant une connexion au backend SAP/R3 via un pool de
    * connexion.
    * @param userLocale  - la locale de l'utilisateur
    * @param user        - utilisateur pour lequel il faut une connection
    * @param systemAlias - système pour se connecter
    * @return une connexion au backend SAP/R3.
    * @throws ConnectionPoolException
    *             levée en cas d'erreur.
   public IConnection getConnection(
         Locale userLocale,
         IUserContext user,
         String systemAlias) throws ConnectionPoolException {
      ConnectionProperties prop = null;
      IConnection connection = null;
      IConnectorGatewayService cgService = null;
      try {
         // Connector Gateway Service.
         cgService = (IConnectorGatewayService) PortalRuntime
               .getRuntimeResources().getService(IConnectorService.KEY);
         if (cgService == null) {
            throw new ConnectionPoolException(
                  "Error in get Connector Gateway Service...");
         IPortalComponentRequest aRequest;
         if (systemAlias == null) {
            throw new ConnectionPoolException(
                  "System alias 'systemAlias' name is null...");
         // Demande la connexion au service :
         prop = new ConnectionProperties(userLocale, user);
         connection = cgService.getConnection(systemAlias, prop);
      } catch (Exception ex) {
         throw new ConnectionPoolException(ex);
regards
Guillaume PATRY

Similar Messages

  • Need to access R3 using IConnectorServiceGateway from jspDynpage.

    Hi
    In abstract portal component i access the R3 using  IConnectorServiceGateway and got the database result. But in jsp dynpage it is not working. please help me.
    Regards
    Krishnamurthy K

    Hello.
    I think this should work
        * Méthode renvoyant une connexion au backend SAP/R3 via un pool de
        * connexion.
        * @param userLocale  - la locale de l'utilisateur
        * @param user        - utilisateur pour lequel il faut une connection
        * @param systemAlias - système pour se connecter
        * @return une connexion au backend SAP/R3.
        * @throws ConnectionPoolException
        *             levée en cas d'erreur.
       public IConnection getConnection(
             Locale userLocale,
             IUserContext user,
             String systemAlias) throws ConnectionPoolException {
          ConnectionProperties prop = null;
          IConnection connection = null;
          IConnectorGatewayService cgService = null;
          try {
             // Connector Gateway Service.
             cgService = (IConnectorGatewayService) PortalRuntime
                   .getRuntimeResources().getService(IConnectorService.KEY);
             if (cgService == null) {
                throw new ConnectionPoolException(
                      "Error in get Connector Gateway Service...");
             IPortalComponentRequest aRequest;
             if (systemAlias == null) {
                throw new ConnectionPoolException(
                      "System alias 'systemAlias' name is null...");
             // Demande la connexion au service :
             prop = new ConnectionProperties(userLocale, user);
             connection = cgService.getConnection(systemAlias, prop);
          } catch (Exception ex) {
             throw new ConnectionPoolException(ex);
    regards
    Guillaume PATRY

  • Lost my phone. reset my icloud password, now its asking me to sign in from the phone before i could use it on the web, and i need to access my icloud account from the web. what shall i do ?

    lost my phone. reset my icloud password, now its asking me to sign in from the phone before i could use it on the web, and i need to access my icloud account from the web. what shall i do ?

    Welcome to the Apple community.
    If you are unable to remember your password, security questions, don’t have access to your rescue address or are unable to reset your password for whatever reason, your only option is to contact Apple ID Support, upon speaking to an operator you should explain that your problem is related to your Apple ID, this way you will not be charged for assistance, even if you don’t have an AppleCare plan.
    The operator will take you through some steps you may have already tried, however they need to be sure they have exhausted all usual approaches before trying to reset your account, so you should try to be helpful and show patience with the procedure.
    The operator will need to verify they are speaking to the account holder and may ask you some questions that only the account holder could know, and you will need to answer them if the process is to proceed.
    Once the operator has verified your identity they will send a message through to your device which contains an alpha numeric code, which you will need to read back to them.
    Once this has been completed they will send an email to your iCloud email address after a period of 24 hours, so you should check that mail is enabled in your devices iCloud settings.
    Upon receipt of the email, use the reset link provided to reset your password, after which you should be able to make the adjustments to iCloud that you wish to do.

  • Ost my phone. reset my icloud password, now its asking me to sign in from the phone before i could use it on the web, and i need to access my icloud account from the web. what shall i do ?

    i have lost my phone. reset my icloud password, now its asking me to sign in from the phone before i could use it on the web, and i need to access my icloud account from the web. what shall i do ?

    Welcome to the Apple community.
    If you are unable to remember your password, security questions, don’t have access to your rescue address or are unable to reset your password for whatever reason, your only option is to contact Apple ID Support, upon speaking to an operator you should explain that your problem is related to your Apple ID, this way you will not be charged for assistance, even if you don’t have an AppleCare plan.
    The operator will take you through some steps you may have already tried, however they need to be sure they have exhausted all usual approaches before trying to reset your account, so you should try to be helpful and show patience with the procedure.
    The operator will need to verify they are speaking to the account holder and may ask you some questions that only the account holder could know, and you will need to answer them if the process is to proceed.
    Once the operator has verified your identity they will send a message through to your device which contains an alpha numeric code, which you will need to read back to them.
    Once this has been completed they will send an email to your iCloud email address after a period of 24 hours, so you should check that mail is enabled in your devices iCloud settings.
    Upon receipt of the email, use the reset link provided to reset your password, after which you should be able to make the adjustments to iCloud that you wish to do.

  • Lost my phone. reset my icloud password, now its asking me to sign in from the phone, and i need to access my icloud account from the web. what shall i do ?

    lost my phone. reset my icloud password, now its asking me to sign in from the phone before i could use it on the web, and i need to access my icloud account from the web. what shall i do ?

    The Apple ID and Password that was used to Activate the iDevice is required
    If you do not have that information you will not be able to use the Device.
    Activation Lock in iOS 7  >  http://support.apple.com/kb/HT5818

  • Accessing BW/ERP/CRM from portal

    Does any one have step by step guides for accessing BW/ERP/CRM from portal?
    I would apprciate if you guys can share issues faced and resolutions for accessing them through portal.
    Thanks,
    Anika

    hi
    BW/ERP/CRM access from portal is governed by a single concept of single sign on  where actually you integrate them through logon ticket otherwise you can use application integrator component for user mapping
    There is step by step guide of BW 3.5 integration with portal  in sdn as well
    http://help.sap.com/saphelp_nw04/helpdata/en/a3/7b583c2439e66fe10000000a114084/frameset.htm.
    on similar grounds you will have CRM too
    Portal and R3/CRM/BW in different windows domains
    please do not forget points
    with regards
    subratokundu

  • Where to find  Portal WebService from Portal Service

    Hello,
    I've managed to create a portal service. i would now like to use it as a web service.
    I've found document describing the process, however when try to create a portal object I'm proposed with the choice for portal service, Portal Componant and KM Componant , but not the needed "Web Service from portal Service" .
    Does anyone know what you have to get/add/activate to have this option ?
    i'm on NWDS version 7.0.14
    regards
    Guillaume PATRY

    Hi Guillame,
    To expose your Portal Service as a Web Service, follow the steps :
    1). Select the project containing the Portal Service you wish to expose as a web service.Generate Portal Web Service with PDK Wizard by choosing Portal Web Service From Portal Service.
    2). Select the interface by clicking the browse button.You can only expose the interface that are defined in your Portal Service Project.
    3). Select the method you want to expose to the web service.WSDL files will be generated.
    4). The portalapp.xml will be automatically updated with the WSDL entries.
    5). Deploy the Portal Service on Portal.
    6). View the Web Service on Portal in the following path :
    System Administration --> Support --> Portal Runtime --> SOAP Admin --> Web Services
    7). The generated WSDL can be viewed with the URL :
    http://<server>/irj/servlet/prt/soap/com.sap.portal.prt.soap.<servicename>.
    Hope this does solves your problem.
    Do award points if found helpful.
    Thanks & Regards
    Gourav.

  • Calling a abstract portal component from portal service

    Hi
    Can i access a abstract portal component from portal service?
    My requirement is i have a method called getsessionID in portal service. My portal service is enabled as a webservice. Who ever consumes my webservice they will call this method.
    This method in portal service should call a method in abstract portal component to return the session id of the user.
    is this possible.
    Thanks in advance
    Kishore

    Hi Kishore,
           This is impossible. The AbstractPortalComponent is a servlet and it can only be executed via URL. It is easy to execute the component via url but you have to pass the logon information. Also it will run under a user context that you have specified(while passing the logon information) when calling the url. I think you ought to consider a different approach.
            Prakash Singh

  • Portal Webservice from Portal Service

    Hello community...
    I'm trying to build a Portal Webservice from a Portal Service, but the wizard doesn't appear in my Portal Application Object. There are only Portal Components, Portal Services and a RF Component Wizard. Are there any options configuring the NWDS to show the other wizards like the "Portal Webservice from Portal Service" one or do I have an old version of the nwds (7.0.14)?

    Hi Ozzie,
    in newer NWDS versions this wizard doesn't exist any more.
    [http://help.sap.com/saphelp_nw70/helpdata/en/1f/4554426dd13555e10000000a1550b0/frameset.htm|http://help.sap.com/saphelp_nw70/helpdata/en/1f/4554426dd13555e10000000a1550b0/frameset.htm] describes how to create a web service from a portal service.
    I personally didn't create a web service by this description however. I just created a normal Java class and created a Web Service out of this class (using EAR deployment).

  • How can I using tpcall from one service to another service in the same server

    When I using tpforward between two services in one server, it's working ok. However,
    when I using tpcall from one service to another service, it's failed?
    anybody can tell me why?
    thanks
    george

    "george" <[email protected]> wrote:
    >
    When I using tpforward between two services in one server, it's working
    ok. However,
    when I using tpcall from one service to another service, it's failed?
    anybody can tell me why?Basically, tpcall:ing another service in the same server is a no-no, unless you
    a) are running a multi-threaded server (requires TUXEDO 7 or newer + compilation
    options) or
    b) use tpacall() instead of tpcall() and specify the flag TPNOREPLY. This is probably
    not what you want to accomplish, though.
    The reason is that TUXEDO servers by default (and always in versions before 7)
    are single-threaded. If service A and B both reside in server X, server X will
    be busy taking care of the call to A. If A makes a call to B, the call will be
    put on the queue to X, but X will not look at the queue until it is done with
    A, which won't happen until B returns... deadlock!
    You can play tricks with starting multiple instances of X, but in the end you
    will always face a risk (something lika a race-condition) for a dead-lock.
    Solution: Move service B to another server (usually quite easy) OR switch to multi-threading,
    if that's possible. Just make sure all code your service calls is MT-safe as well...
    thanks
    georgeHope this helps you,
    /Per

  • I need to access my MacBook Pro from Berlin with my MacAir book

    Hello and thank you advance
    I need to access my MacBook Pro which is in London from Berlin with my MacAir Book.
    I bought the app SERVER on recommendation from a One to One trainer but I am now told I need a Static IP and not a dynamic one. For me to change to a Static IP means going to a Business Account with BT and it is VERY expensive for my needs.   How can I access my laptop from Berlin please??? I live in London and have BT Infinity there.  The app Server does not indicate I need a Static IP when buying it. Do I need to buy something else?  dare I say that I could access my previous ..."windows" laptops without any problem?..... can anybody help me? I am an opera critic,NOT an expert... sorry......  Both Laptops run Yosemite and are about three years old.

    You can't use the Mac OS X disc that came with another computer to upgrade another Mac because it's not supported. Buy Snow Leopard > http://store.apple.com/us/product/MC573/mac-os-x-106-snow-leopard
    You shouldn't lose data, but you must make a backup before

  • Need Sample code to retrieve Data from Portal DB(Oracle)

    Would anyone provide me steps to create application with a sample code to retrieve data from portal DB which is oracle and see the output in table format.

    Hi Bris ,
    The sample code , you didnt specified from where do u want to access the oracle thorough java code or through webdynpro .
    Sample code to access through Java
    import java.sql.*;
    class Customer
    public static void main(String args[]) throws SQLException
    DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver());
    System.out.println("Connecting to the database...");
    try
    Connection cn=DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:orcl","scott","t");
    Statement st=cn.createStatement();
    ResultSet rs=st.executeQuery("select 'Connected' from dual");
    rs.next();
    String s=rs.getString(1);
    System.out.println(s);
    st.close();
    cn.close();
    catch(Exception ex)
    System.out.println("The exception raised is:" + ex);
    [code]
    If accessing through JDBC datasorce.
    https://www.sdn.sap.com/irj/sdn/thread?threadID=328550
    https://www.sdn.sap.com/irj/sdn/thread?threadID=309386
    [code]
    package com.dhl.employeemodel;
    import java.sql.Connection;
    import javax.naming.Context;
    import javax.naming.InitialContext;
    import javax.sql.DataSource;
    public class DBConnectionManager {
         Connection connection;
          * @return
         public Connection getConnection() {
              try
                   Context jndiContext = new InitialContext();
                   DataSource ds = (DataSource)jndiContext.lookup("jdbc/MyAlias");
                   connection = ds.getConnection();
             catch(Exception connectionErrEx)
                   //connectionErrEx.printStackTrace();
                   return null;
              return connection;
    Thanx
    Pankaj

  • Read Iview component profile from Portal Service

    Is there any way this can be done?

    We have a situation where we need to define  application parameters that is to be accessed across different iviews and a portal service. These application parameters can be   modified by content administrators if it's at an iview level. We are trying to see if this can be done without  the use of system landscapes which is available only to System administrators.

  • How to make use of the portal service "xsltransform"

    Hi all,
    I am using EP5 SP4 and is trying to create a component to do xml transformation by using the portal service "xsltransform". However when I run the code (which is reference to an example on web), the following error occured:
    javax.naming.NotContextException: broker should be a Context
         at com.sapportals.portal.prt.repository.AbstractHierarchicalContext.lookup(AbstractHierarchicalContext.java:139)
         at com.sapportals.portal.prt.repository.AbstractHierarchicalContext.lookup(AbstractHierarchicalContext.java:140)
         at com.sapportals.portal.prt.repository.AbstractHierarchicalContext.lookup(AbstractHierarchicalContext.java:74)
         at javax.naming.InitialContext.lookup(InitialContext.java:345)
         at com.mk.kmbrowserid.MkKmBrowseRID$MkKmBrowseRIDDynPage.doProcessBeforeOutput(MkKmBrowseRID.java:167)
    Here is my code:
    Hashtable env = new Hashtable();
         env.put(Context.INITIAL_CONTEXT_FACTORY, "com.sapportals.portal.prt.registry.PortalRegistryFactory");
         InitialContext context = new InitialContext(env);
         IXSLTransformService xslTransService = (IXSLTransformService) context.lookup("/broker/services/"+IXSLTransformService.KEY);
         //retrieve the xsl file and put into string
         String line;
         StringBuffer styleSheet = new StringBuffer();
         IResourceContext resourceContext = new ResourceContext(myUser);
         IResourceFactory resFactory = ResourceFactory.getInstance();
    Where the problem is occured in line 167 "IXSLTransformService xslTransService = (IXSLTransformService) context.lookup("/broker/services/"+IXSLTransformService.KEY);"
    Do any one know how to solve this problem? And setting / config should be done before the service "xsltransform" can be used?
    Thanks
    Sam

    hi
    I need an example please....
    did any one use that FM
    Regards

  • Calling BAPI from Portal Service

    Hi all,
    I have created a KM custom property renderer, what includes a Portal Service.
    Now, I would like to call a BAPI from the renderer component using JCO.
    Does anybody how or whether that works?
    Or does anybody have a sample code how to call a BAPI using JCO from a portal service?
    Thanks
    ISmail

    Hi,
    This is possible.
    Please see the following documentation:
    [http://help.sap.com/saphelp_nwpi711/helpdata/en/48/634503d4e9501ae10000000a42189b/frameset.htm|http://help.sap.com/saphelp_nwpi711/helpdata/en/48/634503d4e9501ae10000000a42189b/frameset.htm]
    Regards,
    Zohar

Maybe you are looking for

  • Error in executing eCATT GUI Script

    Hi I am getting following error (in bold) while executing eCATT GUI Script. This happens only for GUI Scripts and not for TCD scripts. Please help me to solve this issue. <b>0000000195  Test Scrpt ZGUI_SCRIPT4 Version 1 - SECATT [Without Interruption

  • While dragging and dropping text on Mail sometimes is copied instead of moved

    When composing a message under Mail it happens that a word needs to be cut from a place and paste somewhere else in the body. Instead of cutting&pasting most text editors allow the user to drag the selected word (or consecutive words) and drop them a

  • 802.1x wireless connection

    alright so i thought during the keynote speech for software update 2.0, steve jobs said the iphone would support the 802.1x security protocol. The wireless network at my university uses this method and all i see for security choices for a new wireles

  • An error has occurred while opening the Premiere Pro CC 2014: Premiere Debug Event

    An error has occurred while opening the Premiere Pro CC 2014: Premiere Debug Event [c: \ cloudroom \ releases \ 2014.9 \ shared \ adobe \ mediacore \ mediafoundation\API\in I don't know what to do, any help?

  • 5D Mark II to PAL 16x9 DVD

    Is there anyway of encoding Canon's 5D Mark II 30P files to a PAL 16:9 DVD? I've tried Phillip Bloom's converting 30P to 24P, and instead conformed it to 25P, but that also didn't work. The problem I have is when you play it back on a CRT or Plasma T