05-04-2006 3:31 PM
Dear Experts,
Please help me in creating a new SPA/GPA parameter. Please let me know the procedure to this creation.
Thanks in advance.
05-04-2006 3:42 PM
Hi S R,
ABAP programs can access the parameters using the SET PARAMETER and GET PARAMETER statements.
To fill one, use:
SET PARAMETER ID <pid> FIELD <f>.
This statement saves the contents of field <f> under the ID <pid> in the SAP memory. The code <pid> can be up to 20 characters long. If there was already a value stored under <pid>, this statement overwrites it. If the ID <pid> does not exist, double-click <pid> in the ABAP Editor to create a new parameter object.
To read an SPA/GPA parameter, use:
GET PARAMETER ID <pid> FIELD <f>.
This statement fills the value stored under the ID <pid> into the variable <f>. If the system does not find a value for <pid> in the SAP memory, it sets SY-SUBRC to 4, otherwise to 0.
To fill the initial screen of a program using SPA/GPA parameters, you normally only need the SET PARAMETER statement.
Regards,
Tanveer.
Please mark helpful answers.
05-04-2006 3:37 PM
Hi,
Type the SET PARAMETER syntax and double click on the Parameter name and you can create from there.
Or you can create from SE80. Right click on the program and you will get options to create different kinds of objects and parameter should be one of them
Regards,
Ravi
Note : Please mark the helpful answers
05-04-2006 3:42 PM
Hi S R,
ABAP programs can access the parameters using the SET PARAMETER and GET PARAMETER statements.
To fill one, use:
SET PARAMETER ID <pid> FIELD <f>.
This statement saves the contents of field <f> under the ID <pid> in the SAP memory. The code <pid> can be up to 20 characters long. If there was already a value stored under <pid>, this statement overwrites it. If the ID <pid> does not exist, double-click <pid> in the ABAP Editor to create a new parameter object.
To read an SPA/GPA parameter, use:
GET PARAMETER ID <pid> FIELD <f>.
This statement fills the value stored under the ID <pid> into the variable <f>. If the system does not find a value for <pid> in the SAP memory, it sets SY-SUBRC to 4, otherwise to 0.
To fill the initial screen of a program using SPA/GPA parameters, you normally only need the SET PARAMETER statement.
Regards,
Tanveer.
Please mark helpful answers.
05-04-2006 3:48 PM
Hi,
just insert a record in table TPARA with the ID name and a description (you can use transaction SM30)
Regards, Manuel
Please remember to reward points for useful answers