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

Dynamically setting field attributes based on input

Former Member
0 Likes
985

Hi all,

I am trying to see if it is possible to dynamically set field attributes depending on other fields. For example, in screen 1100 of IQ01, I want to make it so that "Certification number" becomes mandatory if "certification status" = 1, and becomes optional if "certification status" = 2,3 or 4.

Is this possible? If so, how?

Regards,

D.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
948

>

> I am trying to see if it is possible to dynamically set field attributes depending on other fields. For example, in screen 1100 of IQ01, I want to make it so that "Certification number" becomes mandatory if "certification status" = 1, and becomes optional if "certification status" = 2,3 or 4.

>

> Is this possible? If so, how?

it is possible only when you have an exit/enhancement spot/badi in the PBO module of the screen.

check if there is any exit for the same.

8 REPLIES 8
Read only

former_member195698
Active Contributor
0 Likes
948

Have you checked this

http://help.sap.com/saphelp_nw70/helpdata/en/9f/dbab6f35c111d1829f0000e829fbfe/content.htm

if your requirement is to do this in Tcode IQ01 then the above answer is not sufficient

Edited by: Abhishek Jolly on Aug 15, 2008 5:41 PM

Read only

naimesh_patel
Active Contributor
0 Likes
948

You can try like:


LOOP AT SCREEN.
IF <certification status> = 1.
  IF SCREEN-FIELD = <Certification number>.
    SCREEN-REQUIRED = 'X'.
  ENDIF.
ELSE.
  IF SCREEN-FIELD = <Certification number>.
    SCREEN-REQUIRED = ' '.
  ENDIF.
  MODIFY SCREEN.
ENDLOOP.

Regards,

Naimesh Patel

Read only

Former Member
0 Likes
949

>

> I am trying to see if it is possible to dynamically set field attributes depending on other fields. For example, in screen 1100 of IQ01, I want to make it so that "Certification number" becomes mandatory if "certification status" = 1, and becomes optional if "certification status" = 2,3 or 4.

>

> Is this possible? If so, how?

it is possible only when you have an exit/enhancement spot/badi in the PBO module of the screen.

check if there is any exit for the same.

Read only

0 Likes
948

Thank you. Yes, I understand how to change the field setting, but I am not sure where to put the code. How do I look if there are exits/badis available for PAI of the screen?

Read only

0 Likes
948

you have to check for PBO and not PAI module.

I will check it and let you know .

Read only

0 Likes
948

can you tell me which screen you are looking for.

Since in the above you mentioned 1100 screen , seems there is no screen 1100.

Read only

0 Likes
948

It's the IS-U specific data screen, comes up after I enter the Material number in the initial screen, and press enter.

According to technical information it is:

Program Name: SAPLE10R

Screen Number: 1100

Read only

0 Likes
948

I don't find any enhancements for that screen flow logic, checked it with the screen number and program you provided.