‎2010 Jun 14 2:52 PM
Hi,
I am designing one module pool for developing a Custom Infotype. Here I want to do a dynamic field selection:
Suppose there three 3 fields in the screen: A,B and C. Also, Field A have can two value, like 'X' and 'Y'.
But the Field A has a Search-Help and user can select the values from the match-code. After that, is there any possibility to trigger a user-command , so that I can control the screen based on the selected value.
I have already solved this requirement for Field A having Drop-Down list, instead of having Search Help.
Requirement for control the screen like below -
If user select Value 'X' for field A, then field B and C will be visible in the Screen. Else, user select value 'Y' for field A, then field B will be visible - But, field C will be invisible.
Can you please help me out by solving this problem.
Thanks and Regards-
Debojit.
‎2010 Jun 14 5:42 PM
I'm sorry I don't have a spot to test this, but if memory serves me right, you can put a value in the FctCode for the "A" drop down field. The FCT value will be returned in the OK_CODE (if that's what you named it) . There would be no action within the PAI routine, however, since the FCT is there, it will force it to then return through the PBO routine where you can then make your determinations on field "A" to then make the "B" and "C" field visible in the LOOP SCREEN logic.
This should happen because there is an FCT Code value and it wouldn't require the user to hit Enter or any other "action" key.
‎2010 Jun 15 6:38 AM
Actually, I am using the field with Search-help, the field is not a drop-down list-box.
Edited by: DEBOJIT SAHA on Jun 15, 2010 11:09 AM
‎2010 Jun 15 10:35 AM
Hi Dear,
for ur problem first define a variable and give it value 'x' and 'y'.
start a loop on selection screen and put if condition inside the loop ..
loop at screen
if screen-name = 'ur field name'
screen-invisible = 0.
modify screen .
endif.
endloop0= visible
1= invisible.
try this
Thanks
Girish