‎2007 Oct 22 6:42 AM
Hi Experts,
I am validating a selection screen in my report.In that I am validating a emp. sub-group field.If I am pressing F4 in the selection screen it displays only 14 values.I want to validate those 14 values alone.Not all values in the pa0001 table for the emp.sub-group values.How to validate those values alone with out validating that whole table pa0001 values.
I am need of that its urgent.Kindly reply.
Thanks,
Sakthi.C
***Assure points for reply***
Message was edited by:
Sakthi Saravanan C
‎2007 Oct 22 6:49 AM
Hi sakthi,
ur selection screen field is giving 14 values while u press F4, tht means a search help is attached with it.which is taking the 14 values from a table,
U can find the table while u go n see the search help.
find that Searhelp table and then while Validating use tht in where condition.
This will solve ur probs.
Regards
Debasish.
Rewards if Helpful
‎2007 Oct 22 6:49 AM
Hi sakthi,
ur selection screen field is giving 14 values while u press F4, tht means a search help is attached with it.which is taking the 14 values from a table,
U can find the table while u go n see the search help.
find that Searhelp table and then while Validating use tht in where condition.
This will solve ur probs.
Regards
Debasish.
Rewards if Helpful
‎2007 Oct 22 6:50 AM
create a serch help for the sub group
use function module in <b>at selection screen output</b>
F4IF_FIELD_VALUE_REQUEST and here pass only values selected and get the group related to that only.
reward if useful.
‎2007 Oct 22 6:51 AM
HI,
DO THIS:
AT SELECTION-SCREEN.
SELECT * FROM PA001 WHERE FLD1 IN S_FLD1.
IF sy-subrc <> 0.
MESSAGE e033(zf001).
ENDIF.
‎2007 Oct 22 6:55 AM
If only 14 values you are getting in F4 means you have the F4 functinality for that
Check in <b>At selection-screen on value reqest</b> for that field.
You must be storing that values in some internal table.
Validate that internal table from value table.
‎2007 Oct 22 6:59 AM
Hi Sakthi,
Here u need to use the event AT SELECTION-SCREEN ON VALUE REQUEST event before the Start-of-selection.
TRY THIS:
AT SELECTION-SCREEN ON VALUE REQUEST FOR p_FIELD .
select field from pa0001 into itab where key1(conditon which will help u filter).
if sy-subrc eq 0.
call fm "pop_up_with tabledisplay".
pass the itab to this FM.
READ THE ITAB WITH KEY FIELD.
If sy-subrc eq 0.
p_FIELD = ITAB-FIELD.
endif.
‎2007 Oct 22 7:47 AM