‎2009 Jan 08 11:30 AM
i am using two dates in the selection screen one is ERDAT and another is BNDDT.
these two fileds are obligatory.
i am using radiobutton to enable these field. look at my coding
IF p0 = 'X'.
LOOP AT SCREEN.
IF screen-name = 'S_BNDAT-LOW' OR
screen-name = 'S_BNDAT-HIGH' OR
screen-group1 = 'SC1'.
screen-input = '0'.
MODIFY SCREEN.
CLEAR screen.
ENDIF.
ENDLOOP.
ENDIF.
IF p1 = 'X'.
LOOP AT SCREEN.
IF screen-name = 'S_ERDAT-LOW' OR
screen-name = 'S_ERDAT-HIGH' OR
screen-group1 = 'SC1'.
screen-active = '0'.
MODIFY SCREEN.
CLEAR screen.
ENDIF.
ENDLOOP.
ENDIF.
if i select p1 ,the screen displays error message like fill in all required entry.
if the fileds are not obligatory its working fine.
how to over come this.
Regards,
Bala
Code Formatted by: Alvaro Tejada Galindo on Jan 8, 2009 2:48 PM
‎2009 Jan 08 11:41 AM
Hi ,
When you use obligatory you cannot hide the fields in selection screen. So remove the word obligatory.
If input is not given to your field then display some error message manually.
Place ur error message in
AT SELECTION-SCREEN.
IF p_erdat is initial.
message text-001 type 'E'.
ELSEIF p_bnddt is initial.
message text-002 type 'E'.
ENDIF.
Thanks,
Srilakshmi.
Code Formatted by: Alvaro Tejada Galindo on Jan 8, 2009 2:49 PM
‎2009 Jan 08 11:33 AM
Hi,
if u are making the fields obligatory then u cannot do ur requirement, as SAP checks it first .So don't make the fields obligatory and then see..
Regards,
Nagaraj
‎2009 Jan 08 11:34 AM
Instead of marking the field as OBLIGATORY explicitely, use LOOP AT SCREEN to do that.
Set SCREEN-REQUIRED = 1 to mark a field obligatory
‎2009 Jan 08 11:34 AM
True,
If the fields are mandatory,its not possible to hide them.Right..
Making fields invisible will work only if u want to enter only one of the two fields..
‎2009 Jan 08 11:41 AM
Hi ,
When you use obligatory you cannot hide the fields in selection screen. So remove the word obligatory.
If input is not given to your field then display some error message manually.
Place ur error message in
AT SELECTION-SCREEN.
IF p_erdat is initial.
message text-001 type 'E'.
ELSEIF p_bnddt is initial.
message text-002 type 'E'.
ENDIF.
Thanks,
Srilakshmi.
Code Formatted by: Alvaro Tejada Galindo on Jan 8, 2009 2:49 PM
‎2009 Jan 08 11:51 AM
hi..
step 1) just use "MODIFY ID " for the field in your selection-screen to make it into one group.
EX:
select-options: s_cajo for tcj_documents-cajo_number
modif id cas.
step2) in your at selection-screen .
just loop the screen and make it required..as follows:
EX:
loop at screen.
if screen-group1 = 'CAS'.
screen-required = 1.
screen-input = 0.
screen-active = 1.
endif.
modify screen.
endloop.
I think it will helps you..
UR's
GSANA
Code Formatted by: Alvaro Tejada Galindo on Jan 8, 2009 2:49 PM