on 10-16-2016 8:05 PM
Hi,
Is there a way of reading PID value from SU3, when I have tried to record a script in ITS, it doesn't record any of the steps I take to filter and copy value, so I would like to directly read it,
This is for a GUI for Windows user.
Many Thanks,
Daniel.
Create a RFC function module similar to the following:
FUNCTION ZRHP0_GET_USER_PARAMETER.
*"----------------------------------------------------------------------
*"*"Local Interface:
*" IMPORTING
*" VALUE(PARAMETER_ID) LIKE USR05-PARID
*" EXPORTING
*" VALUE(PARAMETER_VALUE) LIKE USR05-PARVA
*" VALUE(RC) LIKE SY-SUBRC
*"----------------------------------------------------------------------
CLEAR parameter_value.
SELECT SINGLE parva FROM usr05 INTO parameter_value
WHERE bname = sy-uname
AND parid = parameter_id.
rc = syst-subrc.
ENDFUNCTION.
In your Personas script you can create a method like the following:
function getUserParameter(z_param_id)
{
var rfc = session.createRFC("ZRHP0_GET_USER_PARAMETER");
//Input
rfc.setParameter("PARAMETER_ID", z_param_id);
//Return
rfc.requestResults('["PARAMETER_VALUE", "RC"]'); rfc.send();
return rfc.getResult("PARAMETER_VALUE");
}
It can be called in the same script like the following. In the I get the IFL pid returned (Function Location).
var z_func_loc = getUserParameter('IFL');
Hope this helps!
Thanks, Brian
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You could use the function module BAPI_USER_GET_DETAIL via RFC, it returns the parameter values for a user.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
9 | |
7 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.