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 create variant for csutom screen

Sandeep_Kumar
Product and Topic Expert
Product and Topic Expert
0 Kudos
698

Hi ,

I have created a custom screen and i want to save the inputs as a variant .

I tried below FM:

RS_CHANGE_CREATED_VARIANT

RS_CREATE_VARIANT

RS_RWSET_CREATE_VARIANT

And also i tried changing the PF status to include the save variant option but its not working as well.

Your inputs will be of great help.

Thanks in Advance!

Sandeep

1 ACCEPTED SOLUTION

Former Member
0 Kudos
259

Hi Sandeep,

Use FM RS_CREATE_VARIANT and fill all the parameters along with the tables parameter and specify the screen name and kind of screen in the parameter VSCREENS STRUCTURE RSDYNNR.

hope this helps

regards,

kinshuk

5 REPLIES 5

Former Member
0 Kudos
259

Hi Sandeep,

Welcome to SDN, I am not very sure, we can only create variants for Selection-Screens, not the screens what we had designed, for selection screen, the save button appears automatically, one thing you can do is debug the standard code in selection-screen, you may get some solutions from it.

Regards:-

Santosh

messier31
Active Contributor
0 Kudos
259

Hi Sandeep,

We can create variant only for selection screen. It doesn't matter if it is standard screen or custom screen. we dont have to write any code for this, the fucntionality is provided by SAP itself.

Now if your custom screen is not a selection screen.. Then you will have do little hom work to acheive the functionality. Just check out the pseudologic for the same.

1. Create a custom table which will store the values for variant.

2. Create push button or pfstatus on click of which the inputs on the

selection screen will be saved in the table created in above table.

3. Also add the functionality to delete or modify this variant.

Thats all..I do understand it is little tedious task..but i doubt about any other possible method.

Let me know if need more inputs on this..

Enjoy SAP.

Pankaj Singh.

Former Member
0 Kudos
260

Hi Sandeep,

Use FM RS_CREATE_VARIANT and fill all the parameters along with the tables parameter and specify the screen name and kind of screen in the parameter VSCREENS STRUCTURE RSDYNNR.

hope this helps

regards,

kinshuk

Sandeep_Kumar
Product and Topic Expert
Product and Topic Expert
0 Kudos
259

Hi ,

Thanks for ur valuable help!

I have created the variant using RS_CREATE_VARIANT and after that we have to add another button to get the varaint as input parameters and it really takes lots of time ...

Sandeep

0 Kudos
259

That's fine as long as your screen field names are no longer than 8 characters. Otherwise you can't use RS_CREATE_VARIANT.

Not sure if there's any way of creating Screen Variants using a standard function module??? I'm currently trying to find out as I'm doing something similar.

Regards,

Chris.