Application Development and Automation 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: 
Read only

Regarding obligatory Fields

Former Member
0 Likes
990

Hi experts,

Lets say I have a report program PRG1.

there is a selection screen for that program.

Now i am in second report program PRG2.

Is there any way to find out the first program's(PRG1) screen number and obligatory fields of that program from second program.

i mean any table which i can read by just passing the program name.

please guide me. its really urgent.

thanks in advance.

azad.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
953

Use this FM to get selection-screen values from other program to ur progarm RS_REFRESH_FROM_DYNAMICAL_SEL ,

RS_REFRESH_FROM_SELECTOPTIONS

and use sy-cprog and do not use sy-repid.

Message was edited by:

Seshu Maramreddy

Hi experts,

Lets say I have a report program PRG1.

there is a selection screen for that program.

Now i am in second report program PRG2.

Is there any way to find out the first program's(PRG1) screen number and obligatory fields of that program from second program.

i mean any table which i can read by just passing the program name.

please guide me. its really urgent.

thanks in advance.

azad.

8 REPLIES 8
Read only

Former Member
0 Likes
953

Hi

From the second program write a select statement to a Std table (something like D020*.. ( like D010SINF) .) which stores the Screen Number and program number by giving the first program name and will come to know about the first program details.

Reward points if useful

Regards

Anji

Read only

0 Likes
953

Thanks for ur reply ...

But how can i get the obligatory field from this table???

Read only

RichHeilman
Developer Advocate
Developer Advocate
0 Likes
953

It appears that you get get the screen numbers by using the function module RS_ALL_SELECTIONSCREENS.

Regards,

RIch Heilman

Read only

0 Likes
953

Also, you can use the functino module RPY_DYNPRO_READ to get the list of fields in the screen, and there is a column for obligatory.

Check out the tables parameter, FIELDS_TO_CONTAINERS, here it should list all of the selection screen elements, check the column name REQU_ENTRY to see if the field is obligatory.

Regards,

RIch Heilman

Read only

Former Member
0 Likes
954

Use this FM to get selection-screen values from other program to ur progarm RS_REFRESH_FROM_DYNAMICAL_SEL ,

RS_REFRESH_FROM_SELECTOPTIONS

and use sy-cprog and do not use sy-repid.

Message was edited by:

Seshu Maramreddy

Read only

0 Likes
953

How will i distinguish which field is obligatory...?

Read only

0 Likes
953

Hi

You can't know whether that field is obligatory or not

but only thing you know that whether that field is a paramter or select -options and the values for sign, option, low and high etc from this fun module

RS_REFRESH_FROM_SELECTOPTIONS

Reward points if useful

Regards

Anji

Read only

Former Member
0 Likes
953

Hi,

I think it is better to check the other report program manullay to check for required fields..

If the field is made required in the event START-OF-SELECTION..Then none of the FMs would be able to provide you that information...

Thanks,

Naren