Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

How to set attributes for select-options in a report variant created in an ABAP programme?

iris_siebrands2
Explorer
0 Kudos
364

Hi ABAP-Dev-community,

I'm creating report variants in an ABAP report by using the function RS_CREATE_VARIANT.

Now I should be able to set attributes for some of the select-options / parameters in the variant, e.g. for a) protecting the selection criteria and/or b) hiding it.

Unfortunately I couldn't find any SAP-function or class which offers the possibilty to do this automatically in an ABAP report, that is without processing a selection screen to manually change the attributes of the respective variants.

Has anybody a solution how to do this in an ABAP report fully automatically??

Many thanks in advance,

Iris

1 ACCEPTED SOLUTION

Sandra_Rossi
Active Contributor
282

After the creation, you may call RS_CHANGE_CREATED_VARIANT (to change) and pass the protection through the parameter OBJECTS. This parameter doesn't exist in RS_CREATE_VARIANT.

2 REPLIES 2

Sandra_Rossi
Active Contributor
283

After the creation, you may call RS_CHANGE_CREATED_VARIANT (to change) and pass the protection through the parameter OBJECTS. This parameter doesn't exist in RS_CREATE_VARIANT.

282

Hi Sandra,

Thanks very much for your quick reply and most helpful answer!

Yes, setting the PROTECTED attribute works fine. That's more than the documentation on this table-parameters, OBJECTS, lets hope for 😉 Interestingly enough: setting the INVISIBLE attribute is, indeed, not (yet?) supported. But in my case protection is key and you solved the task for me, great!

Kind regards,

Iris