‎2008 Apr 19 7:28 AM
hi,
how to validate document number(bkpf-blart) in the selection screen such that it should accept only document types as KD,KC,KG,KA.
‎2008 Apr 19 7:33 AM
hi,
using the event "AT SELECTION-SCREEN" or "AT SELECTION-SCREEN ON FIELD" event we can validate it.
‎2008 Apr 19 7:37 AM
Hi,
If u want to validate the selection-screen input values, you need to use the event "AT SELECTION-SCREEN"
ex:-
AT SELECTION-SCREEN ON BLART.
select single blart from bkpf into bkpf
where blart = 'KD'
and blart = 'KC'
and blart = 'KG'
and blart = 'KA'.
if sy-subrc ne 0.
message i009(zcsmsg).
submit (sy-repid) via selection-screen.
endif.
Reward,if useful.
Thanks,
Chandu
‎2008 Apr 19 7:43 AM
at selection-screen.
if bkpf-blart <> kd and bkpf-blart <> kg.
else if bkpf-blart <> kc and bkpf-blart <> ka.
select the data..............
else.
message e000(z00) with 'enter the available document'.
endif.
endif.
Reward if it useful.
Dara.
‎2008 Apr 19 7:48 AM
Write the following code:
At Selection-Screen Output.
If bkpf-blart = 'KD' or bkpf-blart = 'KC' or bkpf-blart = 'KG' or bkpf-blart = 'KA'.
else.
message e000(zmes) with 'Enter Valid data'.
endif.
Reward if useful.