How to pass current user credential for PAPI service execution

Hi All,
As per my requirement I am using the SAP ME PAPI WS to start the SFC. I have used the SAPME PAPI Interface action block in ME within BLS and searched the service and operation also. Required input parameter mapping is also done and I have successfully executed the BLS and SFC is started in ME. In SAPME PAPI Interface action block I have used Credential alias which is standard configuration in MEINT for user MESYS.
Now what I have seen is that, in ME the SFC is started by user MESYS. But I want to pass the user who is currently executing. Is there any way to pass the current user credential or session for executing the PAPI service. My final target is to use the BLS in IRPT through Xacute query.
Thanks in Advance
Chandan

Hi Sergiy,
It is only required for Sfc Start operation. It is a generic requirement for all PAPI WS. User ref is not available for all services. I have taken sfc Start operation as an example. But for  complete SFC operation there is no user ref. in Request structure. Then what would be our generic way to execute it through current user credential.
Thanks
Chandan

Similar Messages

  • How to pass the User Group for a SQ00 Transaction iView

    Hello,
    To start off, I am relatively new to SAP technology in general.  I may be missing something obvious.
    I am trying to create an SAP Transaction iView in our EP Portal that will call the SQ00 transaction (start query) and run a particular query against our R/3 backend.  I set the Transaction Code to: SQ00, the application parameters to: RS38R-QNUM=<my query> and the OK Code to: SHOW and the System to the System alias for our R/3 system.
    My problem is that the query that I need to run is not in the default User Group that comes up by default.  So I get a screen that has the query field (RS38R-QNUM) correctly populated but the error that the query has not been created.  From that screen I can navigate to the correct User Group and then run query.  There does not seem to be a User Group field on the screen, you change it by accessing a different menu, so I do not know how to call the screen for a particular User Group.
    Is their an application parameter that I can initially pass to set the User Group?
    Thank you.

    And my lecturer is suck, every lectures she just read
    the slices and never explains why and how they are.
    (If ask her, she talks and talks rubbish and
    eventually I get nothing)Maybe you should drop the class and complain to the administration.

  • How to find current user name on a LAN machine....

    how to find current user name in a remote machine in LAN .
    how to find current user name on a local machine in LAN .

    how to find current user name in a remote machine in
    LAN .Many users may be logged on concurrently on the remote machine.
    how to find current user name on a local machine in
    LAN .The user who is running the code in the process would be obtainable via:
    System.getProperty("some property goes here");
    I leave it to you to look at the API documentation for System.getProperties() to see what property name you would retrieve.

  • HOW TO CREATE A USER-EXIT FOR MB31 GOODS RECEIPT

    Hy,
    <b>HOW TO CREATE A USER-EXIT FOR MB31</b>
    TO COMPARE ORDER QTY CONFIRMED AND GOODS RECEIPT QTY
    ( IF GR QTY GREATER THAN CONFIRMED QTY ERROR MESSAGE SHOULD COME AND NOT ALLOW TRANSCATION TO PROCEED).
    POINTS CONFIRMED.
    REGARDS,
    KARTIKEY.

    Hi Rawat,
       You Don't need to create User Exits,but you need to find user Exits.Below are list of user Exits for MB31.
    Use proper exit as per your requirement.
    Exit Name     Description
    MBCF0002     Customer function exit: Segment text in material doc. item
    MBCF0005     Material document item for goods receipt/issue slip
    MBCF0006     Customer function for WBS element
    MBCF0007     Customer function exit: Updating a reservation
    MBCF0009     Filling the storage location field
    MBCF0010     Customer exit: Create reservation BAPI_RESERVATION_CREATE1
    MBCF0011     Read from RESB and RKPF for print list in  MB26
    MB_CF001     Customer Function Exit in the Case of Updating a Mat. Doc.
    award points if ans is useful.
    Regards,
    Albert

  • How to  find the user exit for a screen..

    Hi,
    plz help me how to find the user exit for a screen..?
    Regards
    Anbu

    Hi,
    check this program this will give you the list of user-exit and BADI for the perticular Tcode.
    REPORT  zuserexit_badi.
    TABLES : tstc,
    tadir,
    modsapt,
    modact,
    trdir,
    tfdir,
    enlfdir,
    sxs_attrt ,
    tstct.
    DATA : jtab LIKE tadir OCCURS 0 WITH HEADER LINE.
    DATA : field1(30).
    DATA : v_devclass LIKE tadir-devclass.
    PARAMETERS : p_tcode LIKE tstc-tcode,
    p_pgmna LIKE tstc-pgmna .
    DATA wa_tadir TYPE tadir.
    START-OF-SELECTION.
      IF NOT p_tcode IS INITIAL.
        SELECT SINGLE * FROM tstc WHERE tcode EQ p_tcode.
      ELSEIF NOT p_pgmna IS INITIAL.
        tstc-pgmna = p_pgmna.
      ENDIF.
      IF sy-subrc EQ 0.
        SELECT SINGLE * FROM tadir
        WHERE pgmid = 'R3TR'
        AND object = 'PROG'
        AND obj_name = tstc-pgmna.
        MOVE : tadir-devclass TO v_devclass.
        IF sy-subrc NE 0.
          SELECT SINGLE * FROM trdir
          WHERE name = tstc-pgmna.
          IF trdir-subc EQ 'F'.
            SELECT SINGLE * FROM tfdir
            WHERE pname = tstc-pgmna.
            SELECT SINGLE * FROM enlfdir
            WHERE funcname = tfdir-funcname.
            SELECT SINGLE * FROM tadir
            WHERE pgmid = 'R3TR'
            AND object = 'FUGR'
            AND obj_name EQ enlfdir-area.
            MOVE : tadir-devclass TO v_devclass.
          ENDIF.
        ENDIF.
        SELECT * FROM tadir INTO TABLE jtab
        WHERE pgmid = 'R3TR'
        AND object IN ('SMOD', 'SXSD')
        AND devclass = v_devclass.
        SELECT SINGLE * FROM tstct
        WHERE sprsl EQ sy-langu
        AND tcode EQ p_tcode.
        FORMAT COLOR COL_POSITIVE INTENSIFIED OFF.
        WRITE:/(19) 'Transaction Code - ',
        20(20) p_tcode,
        45(50) tstct-ttext.
        SKIP.
        IF NOT jtab[] IS INITIAL.
          WRITE:/(105) sy-uline.
          FORMAT COLOR COL_HEADING INTENSIFIED ON.
    Sorting the internal Table
          SORT jtab BY object.
          DATA : wf_txt(60) TYPE c,
          wf_smod TYPE i ,
          wf_badi TYPE i ,
          wf_object2(30) TYPE c.
          CLEAR : wf_smod, wf_badi , wf_object2.
    Get the total SMOD.
          LOOP AT jtab INTO wa_tadir.
            AT FIRST.
              FORMAT COLOR COL_HEADING INTENSIFIED ON.
              WRITE:/1 sy-vline,
              2 'Enhancement/ Business Add-in',
              41 sy-vline ,
              42 'Description',
              105 sy-vline.
              WRITE:/(105) sy-uline.
            ENDAT.
            CLEAR wf_txt.
            AT NEW object.
              IF wa_tadir-object = 'SMOD'.
                wf_object2 = 'Enhancement' .
              ELSEIF wa_tadir-object = 'SXSD'.
                wf_object2 = ' Business Add-in'.
              ENDIF.
              FORMAT COLOR COL_GROUP INTENSIFIED ON.
              WRITE:/1 sy-vline,
              2 wf_object2,
              105 sy-vline.
            ENDAT.
            CASE wa_tadir-object.
              WHEN 'SMOD'.
                wf_smod = wf_smod + 1.
                SELECT SINGLE modtext INTO wf_txt
                FROM modsapt
                WHERE sprsl = sy-langu
                AND name = wa_tadir-obj_name.
                FORMAT COLOR COL_NORMAL INTENSIFIED OFF.
              WHEN 'SXSD'.
    For BADis
                wf_badi = wf_badi + 1 .
                SELECT SINGLE text INTO wf_txt
                FROM sxs_attrt
                WHERE sprsl = sy-langu
                AND exit_name = wa_tadir-obj_name.
                FORMAT COLOR COL_NORMAL INTENSIFIED ON.
            ENDCASE.
            WRITE:/1 sy-vline,
            2 wa_tadir-obj_name HOTSPOT ON,
            41 sy-vline ,
            42 wf_txt,
            105 sy-vline.
            AT END OF object.
              WRITE : /(105) sy-uline.
            ENDAT.
          ENDLOOP.
          WRITE:/(105) sy-uline.
          SKIP.
          FORMAT COLOR COL_TOTAL INTENSIFIED ON.
          WRITE:/ 'No.of Exits:' , wf_smod.
          WRITE:/ 'No.of BADis:' , wf_badi.
        ELSE.
          FORMAT COLOR COL_NEGATIVE INTENSIFIED ON.
          WRITE:/(105) 'No userexits or BADis exist'.
        ENDIF.
      ELSE.
        FORMAT COLOR COL_NEGATIVE INTENSIFIED ON.
        WRITE:/(105) 'Transaction does not exist'.
      ENDIF.
    AT LINE-SELECTION.
      DATA : wf_object TYPE tadir-object.
      CLEAR wf_object.
      GET CURSOR FIELD field1.
      CHECK field1(8) EQ 'WA_TADIR'.
      READ TABLE jtab WITH KEY obj_name = sy-lisel+1(20).
      MOVE jtab-object TO wf_object.
      CASE wf_object.
        WHEN 'SMOD'.
          SET PARAMETER ID 'MON' FIELD sy-lisel+1(10).
          CALL TRANSACTION 'SMOD' AND SKIP FIRST SCREEN.
        WHEN 'SXSD'.
          SET PARAMETER ID 'EXN' FIELD sy-lisel+1(20).
          CALL TRANSACTION 'SE18' AND SKIP FIRST SCREEN.
      ENDCASE.
    Reagards,
    Bharat.

  • How to pass the USER variable to RPD in 11g?

    I am trying to figure out how to pass the USER variable to the RPD in 11g.
    In 10g, I had define an intializtion block to store the USER variable and pass it to a statement that has to be executed before the query is executed.
    We use the Oracle VPD technology that allows to restrict data access. This is the statement that has to be executed before a query can run.
    select vpd_adwh.setclnvpdcontext_fnc('VALUEOF(NQ_SESSION.cuser)', UPPER(:USER))) from dual
    That is the 10g version and it works fine.
    In 11g, I tried to use
    select vpd_adwh.setclnvpdcontext_fnc('VALUEOF(NQ_SESSION.cuser)', UPPER('VALUEOF(NQ_SESSION.USER)')) from dual
    but this is not working.
    Any help?

    any ideas?

  • How sharepoint understand when user requests for web applications by their DNS names

    HI
    I configured Alternate access mapping in my sharepoint farm for default ,intranet zones
    and spt farm has two web front end servers and they load balancing by F5 device
    in WFE servers there are different web applications are running on different ports
    so here I want to know how load balancing works, load balancing configured in F5 device.
    when users request a webapplication from browser (ex http://cms) where this request will go
    1)when I ping cms and other web applicaations  it returns me a loadbalancer  server IP  for all web applications;
    ping cms : it returns 10.xxx.0.80 , same ip returns when I ping for other web app
    but ex CMS web application run on the 10.xxx.1.26:81 port in sharepoint server
    2) and these sharepoint web applications running on different ports in sharepoint  web servers , so here  how sharepoint understand when user requests for web applications by their DNS names
    http://cms and http://products  etc
    adil

    I'm not sure if the F5 can add a port number (I'm not an expert on load balancers).  But in general if you design the SharePoint site to run on port 81 then you need to have port 81 appended to the request or it won't work.  http://cms in your
    example would take you to http://cms:80 not http://cms:81.  But in general DNS will resolve the address back to the F5 load balancer.  The load balancer will look at the header of the HTTP request (which contains the original address you requested)
    and forward the request to the appropriate web front end IP address.  If your web front end is using one IP address for multiple sites then those sites need to be differntiated by using a custom port like 81 (which must be included in the original request)
    or because a host header was bound to the web application when it was created.  If they are running on different port numbers then the request must include the port number by the time it gets to the SharePoint server.
    Paul Stork SharePoint Server MVP
    Principal Architect: Blue Chip Consulting Group
    Blog: http://dontpapanic.com/blog
    Twitter: Follow @pstork
    Please remember to mark your question as "answered" if this solves your problem.

  • NSAD user directory for shared services not working

    Hi!
    Im trying to configure a MSAD user directory for shared services in Essbase 11.1.2.1. I have done it correctly in Essbase 9.3.1.
    Back then i had to import certificates to the cacerts java file. Is it still necesary? I dont see it mentioned anywhere in the v.11 docs, however, its not working using same parameters. I get an error saying i have specified "either host or port value incorrect".
    Do i have to import certificates or am i missing anything else, can anybody help?
    Thanks!!
    Jorge

    Certificates have nothing to do with MSAD.
    when you reach to "MSAD user configuration" tab in Shared Services, try to see if you can auto configure user by inputting: sAMAccountNmae="some user ID", replace some user ID with your or admin ID, and verify if you can pull the users from the MSAD.

  • How to set Current User in moss 2007 for Authentication....

    Hi Team,
    We have current running website where we have user id to login but now requirement is that user will login with his Email address. Email is stored in active directory, I'm able to login with fba authentication.  
    I'm able to retrieve the user id of current user using Email but
    I am NOT able to set that user id for current user for further authentication using Moss 2007.
    Please find the source code for login and authentication page:
    //---------------------------Login Page--------------------//
        public partial class Login : System.Web.UI.UserControl
            #region Decleration
            string LoginStatus = null;
            string UserCurrent = null;
           static SPUser siteuser;
           // private static string _randomNumbercheck;
            //private static bool IsLoggedin;      
            Random random;
            #endregion       
            #region Page Load
            protected void Page_Load(object sender, EventArgs e)
                this.hplchangepw.Visible = false;
                this.hplmytask.Visible = false;
                string desturl = SPContext.Current.Site.Url;
                if (!IsPostBack)
                    try
                        string str;
     SPWeb web = SPContext.Current.Web;
                             SPUser siteuser = web. .CurrentUser; 
                        //SPUser siteuser = spWeb.EnsureUser(username);
                        str = (siteuser == null ? "" : siteuser.ToString());
                        this.Login.TitleText = "";
                        this.Login.DestinationPageUrl = desturl;
                        //if (HttpContext.Current.Request.UrlReferrer != null)
                        //    if (this.Page.User.Identity.IsAuthenticated && ((Session["test1"].ToString() == _randomNumbercheck) || LoginControl.Class1.IsLoggedIn))
                         if (this.Page.User.Identity.IsAuthenticated)
                               // _randomNumbercheck = "";
                                this.hplregister.Visible = false;
                                this.hplforgetpassw.Visible = false;
                                this.hplchangepw.Visible = true;
                                this.hplmytask.Visible = true;
                                this.Login.Visible = false;
      if (str.StartsWith("fba_"))
                                    string name = str.Split(':').GetValue(1).ToString();
                                    LoginnameLbl.Text = "<b>" + name.ToString() + "</b>,<br><br>Haryana Urban Development Authority Welcomes
    You. <br><br><br><b><i>\"In The Service Of Masses\"</i></b>";
                                else
                                    string name = str.Split('\\').GetValue(1).ToString();
                                    LoginnameLbl.Text = "<b>" + name.ToString() + "</b>,<br><br>Haryana Urban Development Authority Welcomes
    You. <br><br><br><b><i>\"In The Service Of Masses\"</i></b>";
                            else
                                this.hplchangepw.Visible = false;
                                this.hplmytask.Visible = false;
                                this.Login.Visible = true;
                                LoginnameLbl.Text = "";
                                HttpContext.Current.Session.Clear();
                                HttpContext.Current.Session.Abandon();
                    catch (Exception ex)
                        //HttpContext.Current.Session.Clear();
                        //HttpContext.Current.Session.Abandon();
            #endregion
            #region Get Audit Informations
            public void GetUserInfo()
                try
                    string user = Login.UserName;
                    SPSecurity.RunWithElevatedPrivileges(new SPSecurity.CodeToRunElevated(delegate()
                        using (SPSite oSite = new SPSite(SPContext.Current.Site.ID))
                            using (SPWeb web1 = oSite.OpenWeb(SPContext.Current.Web.ID))
                                SPListItem item = null;
                                SPListItemCollection listItems = null;
                                web1.AllowUnsafeUpdates = true;
                                siteuser = web1.EnsureUser(Session["User"].ToString());// spWeb.EnsureUser(login);
                                listItems = web1.Lists["Audit_Trail"].Items;
                                item = listItems.Add();
                                item["User_ID"] = UserCurrent.ToString(); //Request.ServerVariables["AUTH_USER"];
                                string ip = Request.ServerVariables["HTTP_X_FORWARDED_FOR"];
                                if ((ip == null) || (ip == "") || (ip.ToLower() == "unknown"))
                                    ip = Request.ServerVariables["REMOTE_ADDR"];
                                item["IP_Address"] = ip;
                                item["Login_Date"] = System.DateTime.Now;
                                item["Login_Status"] = LoginStatus.ToString();
                                item.Update();
                                web1.AllowUnsafeUpdates = false;
                                web1.Dispose();
                                oSite.Dispose();
                catch (Exception ex)
            #endregion
            #region MD5Encryption
            private string MD5Encryption(string strToEncrypt)
                System.Text.UTF8Encoding ue = new System.Text.UTF8Encoding();
                byte[] bytes = ue.GetBytes(strToEncrypt);
                // encrypt bytes
                System.Security.Cryptography.MD5CryptoServiceProvider md5 = new System.Security.Cryptography.MD5CryptoServiceProvider();
                byte[] hashBytes = md5.ComputeHash(bytes);
                // Convert the encrypted bytes back to a string (base 16)
                string hashString = "";
                for (int i = 0; i < hashBytes.Length; i++)
                    hashString += Convert.ToString(hashBytes[i], 16).PadLeft(2, '0');
                return hashString.PadLeft(32, '0');
            #endregion
            #region Generate Random Code
            private string GenerateRandomCode()
                random = new Random();
                string s = "";
                for (int i = 0; i <= 6; i++)
                    s = string.Concat(s, this.random.Next(10).ToString());
               // _randomNumbercheck = s;
                return s;
            #endregion
            #region Generate Random String
            public string GenerateHashKey()
                StringBuilder myStr = new StringBuilder();
                myStr.Append(Request.Browser.Browser);
                myStr.Append(Request.Browser.Platform);
                myStr.Append(Request.Browser.MajorVersion);
                myStr.Append(Request.Browser.MinorVersion);
                myStr.Append(Request.LogonUserIdentity.User.Value);
                SHA1 sha = new SHA1CryptoServiceProvider();
                byte[] hashdata = sha.ComputeHash(Encoding.UTF8.GetBytes(myStr.ToString()));
                return Convert.ToBase64String(hashdata);
            #endregion
            #region Check User Authentication
            protected void Login_Authenticate(object sender, AuthenticateEventArgs e)
                Utility hu=new Utility();
                int CheckValue = 0;
                string user = Login.UserName;
                if(user.Contains("@"))
                    CheckValue=1;
                //Encrypted Password
                string HPassword = hash.Value;
                // Verify that the username/password pair is valid
                SqlConnection con = new SqlConnection();
                SqlCommand cmd = new SqlCommand();
                con.ConnectionString = System.Configuration.ConfigurationSettings.AppSettings["FBAPortalConnection"];
                if (con.State == ConnectionState.Closed)
                    con.Open();
                cmd.CommandType = CommandType.StoredProcedure;
                cmd.CommandText = "sp_Portal_ValidatePortalUser";
                cmd.Connection = con;
                cmd.Parameters.Add("@ID", SqlDbType.NVarChar, 256).Value = Login.UserName;
                cmd.Parameters.Add("@Password", SqlDbType.NVarChar, 300).Value = HPassword.ToString();
                cmd.Parameters.Add("@CheckVal", SqlDbType.Int).Value = CheckValue;
                cmd.Parameters.Add(new SqlParameter("@P_Return", SqlDbType.NVarChar, 256));
                cmd.Parameters["@P_Return"].Direction = ParameterDirection.Output;
                cmd.ExecuteNonQuery();
                string CurrentUserName = cmd.Parameters["@P_Return"].Value.ToString();
                cmd.Dispose();
                con.Close();
                //int x = hu.ValidatePortalUser(Login.UserName, HPassword.ToString(), CheckValue);
                if (CurrentUserName != "0")
                    Page.Session["User"] = CurrentUserName;
                    string UserName = Session["User"].ToString();
                    UserCurrent = UserName;
                    LoginStatus = "Successfull";
                    GetUserInfo();
                    e.Authenticated = true;
                    //Session["CustomAuthKey"] = MD5Encryption(Request.ServerVariables["Remote_Addr"] + Request.ServerVariables["Http_Cookie"] + Request.ServerVariables["Auth_User"]);
                    Session["CustomAuthKey"] = MD5Encryption(Request.ServerVariables["Remote_Addr"] + Request.ServerVariables["Http_Cookie"] + UserCurrent.ToString());
                    FormsAuthenticationTicket tkt;
                    String cookiestr;
                    HttpCookie ck;
                    tkt = new FormsAuthenticationTicket(1, UserName, DateTime.Now, DateTime.Now.AddMinutes(15), false, GenerateHashKey());
                    cookiestr = FormsAuthentication.Encrypt(tkt);
                    ck = new HttpCookie(FormsAuthentication.FormsCookieName, cookiestr);
                    ck.Path = FormsAuthentication.FormsCookiePath;
                    Response.Cookies.Add(ck);
                else
                    // Username/password are not valid...
                    Login.FailureText = "Invalid Username / password";
                    e.Authenticated = false;
            #endregion
            #region Login Error
            protected void Login_LoginError(object sender, EventArgs e)
                // Determine why the user could not login
                Login.FailureText = "Your login attempt was not successful. Please try again.";
                // Does there exist a User account for this user
                MembershipUser usrInfo = Membership.GetUser(Login.UserName);
                if (usrInfo != null)
                    // Is this user locked out?
                    if (usrInfo.IsLockedOut)
                        Login.FailureText = "Your account has been locked out because of too many invalid login attempts. Please contact the administrator to have your account unlocked.";
                    else if (!usrInfo.IsApproved)
                        Login.FailureText = "Your account has not yet been approved. You cannot login until an administrator has approved your account.";
                    else
                        Login.FailureText = "Invalid UserName / Password";
                        UserCurrent = usrInfo.UserName;
                        LoginStatus = "UnSucessfull";
                        GetUserInfo();
                else
                    Login.FailureText = "Invalid UserName / Password";
            #endregion
            #region Logged In
            protected void Login_LoggedIn(object sender, EventArgs e)
                string UserName = Session["User"].ToString();           
                LoginControl.Class1.IsLoggedIn = true;
                //If User Email is [email protected] it will be invalid. Prompt the user to update the email id. 
                LoginControl.Utility hu = new LoginControl.Utility();
                DataSet dsuser = hu.getUserDetails(UserName);
                string email;
                if (dsuser.Tables[0].Rows.Count > 0)
                    email = dsuser.Tables[0].Rows[0]["Email"].ToString();
                    if (email.Equals("[email protected]"))
                        Response.Redirect("/Pages/UserUpdates.aspx", true);
                    else
            #endregion
    //-------------------------------- Authentication code----------------------------//
      private void authenticateuser()
                try
                    if (SPContext.Current.Web.CurrentUser != null)
                        using (SPSite spSite = new SPSite(SPContext.Current.Site.Url))
                            using (SPWeb spWep = spSite.OpenWeb())
                                Utility hu = new Utility();
    _userid = spWep.CurrentUser.Name;
                                DataSet ds = new DataSet();
                                ds = hu.GetPlotid(_userid);
                                if (ds.Tables[0].Rows.Count > 0)
                                    _plotid = ds.Tables[0].Rows[0]["plotid"].ToString();
                                else
                                    if (!SPContext.Current.Web.UserIsSiteAdmin && !SPContext.Current.Web.UserIsWebAdmin)
                                        if (!SPContext.Current.Web.IsCurrentUserMemberOfGroup(SPContext.Current.Web.Groups["Allottee"].ID))
                                            SPUtility.HandleAccessDenied(new Exception("You do not have access to this page"));
                    else
                    { SPUtility.HandleAccessDenied(new Exception("Please login")); }
                catch (Exception ex)
                    //  lblMessage.Text = "Error:" + ex.Message;
                    ShowMessage("Following error has occured while executing the desried event :- " + ex.Message);
    Mohan Prakash

    1. Current work flow :-In web site the user have to register themselves in the web site and enters his details along with user id, password and email id. Once user
    is registered then he will login with his user id and password. The user id is picked from login control and that set in “SPWeb.CurrentUser” as user id and system uses "Membership.ValidateUser" method to Authenticate user for login. 
    2. New Requirement: we would like to facilitate the user to login with Email id as well as user id. 
    Problem: 
    We replaced "Membership.ValidateUser" method to our own method to Authenticate user with email id/user id and password. 
    When user is login with user id and password it is working successfully but in the case of email id and password –“the email id is picked from user control and set as
    "HttpContext.Current.User.Identity.Name" but we are not getting “SPWeb.CurrentUser” and it shows null value.” 
    We are able to get user id from database using email id of user. Please help us how we can set user id in "SPContext.Current.Web.CurrentUser".
    Mohan Prakash

  • How to get "Current" Room RoomID for logged user ?

    Hi everyone
    Does someone here knows how to get the <i>current</i> <b>RoomID</b> of the Room the user has <u>'open'</u> from a java WebDynpro view ?
    I know I can get the list of rooms for the logged user, but I don't know how to get the <u>open/current</u> room for that user, for querying the roomid in the wdp view after that...
    Thanks
    Best regards
    Manuel
    ps. Sorry for my english, I hope you all understand me...

    Hi,
    I have the same problem, has you solved it? How?
    Thanks in advance,
    Regards,

  • How to pass hardcoded user to ConnectionProperties ?

    Hi,
    How can i pass the hardcoded user to the ConnectionProperties constructor for JCA Connections.
    ConnectionProperties prop = new ConnectionProperties(request.getLocale(), request.getUser());
    i want to pass hardcoded user object in place of - request.getUser()
    Thanks,
    Raags

    Hi Raags,
    you obtain user objects from the user factory object. You have got multiple methods to obtain a user. See javadocs of <a href="https://help.sap.com/javadocs/NW04S/current/se/com/sap/security/api/IUserFactory.html">IUserFactory.</a>
    Example:
    IUserFactory userFactory = UMFactory.getUserFactory();
    IUser myUser = userFactory.getUserByLogonID("MyUser");
    Best regards,
    Martin

  • How to track the user name for audit trail ?

    Hi all,
    I chance the new user name from existing user code, How can i track the document that made by the old user name and the current username. Because when the username change, all the historical will be changed to the current.
    Thanks in advance
    Regards
    Jia shun

    Hi ,
    the problem is usersign is only connect to userid of OUSR. And the changes is on User Name field.
    For example know i make a document PO by using user code manager , user name Jason Butler.
    After that i change my user name become Alex, but the user code still same "manager".
    After that i re-login and update the Qty in PO doc, that i made before. After that i change again the username, the user code still same. After that i click the show history of the document that i made before. The Updated by and created by are always followed by the current user name that i change.
    thanks and regards
    Jia shun

  • How to pass the standard value for the entire datapackage in the routine

    Hi Gurus,
    I have timestamp field in the target. In endroutine , i assigned system date to the tiemstamp field . If i assign sy-datum to that field, if i get 4 datapackage im getting 4 different timestamp for each of the datapackage...
    But my requirement is the timestamp should not vary for each of the datapackage.
    For eg.
    Timestamp
    20111212060205 - Datapackage 1
    20111212060602 - Datapackage 2
    But i need as
    Timestamp
    20111212060205 - Datapackage 1
    20111212060205 - Datapackage 2
    How to pass it?
    Thanks in advance

    you can use tvarv table.
    if the datapackage number = 1,
             use the current timestamp
             overwrite the existing entry in tvarv.
    else
      use timestamp of tvarv

  • How to pass current month as the default value in the prompt

    Hi,
    Could you please tell me how to pass the current month as the default value in the prompt.
    I have a report where month is a prompt. By Default it should ahve current month as the default value along with other months.
    Please let me know the syntax for the same.
    Thanks in advance!!
    Regards
    Sindhu

    Hi,
    what datasource do you have? Is it SAP BW or something else?

  • How can I access user permission for specific items in Sharepoint 2013 via REST API?

    I want to access user permissions for specific items like lists, documents, folders etc. via the REST API.
    Currently I am hitting the following endpoint:
    http://win-5a8pp4v402g/sharepoint_test/site_1/_api/web/getUserEffectivePermissions('win-5a8pp4v402g\\Sharepoint User 2')
    However the response looks like this:
       "d":
           "GetUserEffectivePermissions":
               "__metadata":
                   "type": "SP.BasePermissions"
               "High": "0",
               "Low": "0"
    I cant understand why high and low are both 0? I have added the user to a specific group. Also this is the same result for each of the users. Another thing to note is that I havent added the "Guest" user in the sharepoint server. So when I hit the endpoint for the Guest user, it still shows the same response. So I know there is something I am doing wrong.I want to access permission of a user for a specific item, say a document using the REST API. Can someone tell me how? What would be the endpoint?

    Thanks for the reply. Although this works for Lists, I need to get permissions of documents too. Here is what I have tried:
    http://win-5a8pp4v402g/sharepoint_test/site_1/_api/web/GetFileByServerRelativeUrl('/sharepoint_test/site_1/Documents/file1.txt')/GetUserEffectivePermissions(@user)?@user='i%3A0%23%2Ew%7Cwin-5a8pp4v402g%5Csharepoint%20user%201'
    And the response is:
       "error":
           "code": "-1, Microsoft.SharePoint.Client.ResourceNotFoundException",
           "message":
               "lang": "en-US",
               "value": "Cannot find resource for the request GetUserEffectivePermissions."
    Clearly this doesnt work for a file. Whats wrong?

Maybe you are looking for

  • Excel 2010 cubeformula MDX syntax: how to get all members at a certain level of an AS cube hierarchy?

    I have a cube hierarchy that has full path [Location].[Location Hierarchy].[Department].&[DEPT 07].&[East].&[Manager].&[site code] I can return the full hierarchy using something like [Location].[Location Hierarchy].[All] However, I want to return ev

  • Page fault error while calling reports from forms

    dear friends. when a report is called from forms, just before opening up of background engine the application gets hanged with page fault. One has to forcibly shut down the application before loggin again. The error mesage generated from log file is

  • How do I transfer my iphone songs to a newly restored computer?

    My computer was recently formatted. All of my data was lost. I am using the same computer, and I am wondering how I can transfer my songs on my Iphone to my computer. I am not sure how to access the library my iphone is synced to, because that librar

  • Itunes failing to install

    Hey. For the last week or so I have been trying to download the new itunes (9.0.3) and I have gotten as far as the setup wizard. Everything downloads fine in the beginning but when it asks you to install iTunes it fails to install. As soon as I click

  • Timer problem

    Hi there, I have a strange thing with some timers. I have a main timer: This one is running during a specific time: Set time. When he reaches the Set time is stops. This is ok This timer activates 2 other timers: 1 - Run timer