<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Selection-screen output with mandatory fields in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-output-with-mandatory-fields/m-p/3770622#M907318</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;use loop at screen... and validate the radio buttons&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;when u can post ur code and desired o/p clearly then we can help u out..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Syed&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 06 May 2008 19:45:59 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-05-06T19:45:59Z</dc:date>
    <item>
      <title>Selection-screen output with mandatory fields</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-output-with-mandatory-fields/m-p/3770621#M907317</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have two radio buttons on my screen. Based on the selection I want to display only one of the two select-options. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select-option 1 should be displayed for radiobutton 1&lt;/P&gt;&lt;P&gt;select-option 2 should be displayed for radiobutton 2&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As soon as I make those select-options mandatory I am not able to get the desired result. &lt;/P&gt;&lt;P&gt;Even if the radio button is changed from 1 to 2, the select-option 2 is not displayed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I tried putting the validations the other way by throwing messages and not by making the fields obligatory. Still not successful. Kindly help.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 May 2008 19:36:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-output-with-mandatory-fields/m-p/3770621#M907317</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-06T19:36:14Z</dc:date>
    </item>
    <item>
      <title>Re: Selection-screen output with mandatory fields</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-output-with-mandatory-fields/m-p/3770622#M907318</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;use loop at screen... and validate the radio buttons&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;when u can post ur code and desired o/p clearly then we can help u out..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Syed&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 May 2008 19:45:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-output-with-mandatory-fields/m-p/3770622#M907318</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-06T19:45:59Z</dc:date>
    </item>
    <item>
      <title>Re: Selection-screen output with mandatory fields</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-output-with-mandatory-fields/m-p/3770623#M907319</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Possibly there's not a way to do this, using radiobuttons.&lt;/P&gt;&lt;P&gt;Try discussing your requirement, if it's necessary.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try putting your requirement here, if possible. Then we can help any further.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Brian Gonsales&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 May 2008 19:48:02 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-output-with-mandatory-fields/m-p/3770623#M907319</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-06T19:48:02Z</dc:date>
    </item>
    <item>
      <title>Re: Selection-screen output with mandatory fields</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-output-with-mandatory-fields/m-p/3770624#M907320</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This is my code which is called in selection-screen output.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM selection_screen_modifications.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  IF p_aspt = 'X'.&lt;/P&gt;&lt;P&gt;    LOOP AT SCREEN.&lt;/P&gt;&lt;P&gt;      IF screen-group1 = 'SG2'.&lt;/P&gt;&lt;P&gt;        screen-active = 0.&lt;/P&gt;&lt;P&gt;        MODIFY SCREEN.&lt;/P&gt;&lt;P&gt;      ENDIF.&lt;/P&gt;&lt;P&gt;    ENDLOOP.&lt;/P&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;P&gt;  IF p_ocfd = 'X'.&lt;/P&gt;&lt;P&gt;    LOOP AT SCREEN.&lt;/P&gt;&lt;P&gt;      IF screen-group1 = 'SG1'.&lt;/P&gt;&lt;P&gt;        screen-active = 0.&lt;/P&gt;&lt;P&gt;        MODIFY SCREEN.&lt;/P&gt;&lt;P&gt;      ENDIF.&lt;/P&gt;&lt;P&gt;    ENDLOOP.&lt;/P&gt;&lt;P&gt;    call screen '1000'.&lt;/P&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDFORM.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;The selection-screen is as follows.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-b01.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT-OPTIONS :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*plant&lt;/P&gt;&lt;P&gt;s_werks FOR i_orders-werks NO INTERVALS.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*Parameter&lt;/P&gt;&lt;P&gt;SELECTION-SCREEN BEGIN OF BLOCK b2 WITH FRAME TITLE text-b02.&lt;/P&gt;&lt;P&gt;*OCFD&lt;/P&gt;&lt;P&gt;SELECTION-SCREEN BEGIN OF LINE.&lt;/P&gt;&lt;P&gt;SELECTION-SCREEN COMMENT 3(39) text-co1 FOR FIELD p_aspt.&lt;/P&gt;&lt;P&gt;PARAMETERS: p_aspt RADIOBUTTON GROUP rb1 DEFAULT 'X' USER-COMMAND hit.&lt;/P&gt;&lt;P&gt;SELECTION-SCREEN END OF LINE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*ASPT&lt;/P&gt;&lt;P&gt;SELECTION-SCREEN BEGIN OF LINE.&lt;/P&gt;&lt;P&gt;SELECTION-SCREEN COMMENT 3(39) text-co2 FOR FIELD p_ocfd.&lt;/P&gt;&lt;P&gt;PARAMETERS: p_ocfd RADIOBUTTON GROUP rb1.&lt;/P&gt;&lt;P&gt;SELECTION-SCREEN END OF LINE.&lt;/P&gt;&lt;P&gt;SELECTION-SCREEN END OF BLOCK b2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT-OPTIONS :&lt;/P&gt;&lt;P&gt;*Order creation date - to be displayed for ASPT&lt;/P&gt;&lt;P&gt;s_crd FOR vbak-erdat MODIF ID sg1,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*Date scheduled for OCFD&lt;/P&gt;&lt;P&gt;s_schd FOR vbak-zzsoldate MODIF ID sg2,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*Order number range&lt;/P&gt;&lt;P&gt;s_order FOR vbak-vbeln.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*test mode&lt;/P&gt;&lt;P&gt;PARAMETER : p_test AS CHECKBOX DEFAULT 'X'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECTION-SCREEN END OF BLOCK b1.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 May 2008 19:51:12 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-output-with-mandatory-fields/m-p/3770624#M907320</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-06T19:51:12Z</dc:date>
    </item>
    <item>
      <title>Re: Selection-screen output with mandatory fields</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-output-with-mandatory-fields/m-p/3770625#M907321</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Brian,&lt;/P&gt;&lt;P&gt;The requirement is as follows.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have two radiobuttons.&lt;/P&gt;&lt;P&gt;Rad 1&lt;/P&gt;&lt;P&gt;Rad 2&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If Rad 1 is selected then I want to input Order Creation date (Field1) as mandatory, and Order scheduled date (Field 2) should not be displayed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If Rad 2 is selected then I want to input Order Scheduled date (FIeld2) as mandatory, and order creation date(field1) should not be displayed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If I can make the fields as obligatory at runtime, that may also solve my problem.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 May 2008 19:54:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-output-with-mandatory-fields/m-p/3770625#M907321</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-06T19:54:51Z</dc:date>
    </item>
    <item>
      <title>Re: Selection-screen output with mandatory fields</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-output-with-mandatory-fields/m-p/3770626#M907322</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, Vipul.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To make the select-options obligatory during runtime, you can use this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
screen-required = 1.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;screen-required = 1. (Field is mandatory)&lt;/P&gt;&lt;P&gt;screen-required = 0. (Field in NOT mandatory)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If there's any use for this, just let me know.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Brian Gonsales&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 May 2008 20:28:25 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-output-with-mandatory-fields/m-p/3770626#M907322</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-06T20:28:25Z</dc:date>
    </item>
    <item>
      <title>Re: Selection-screen output with mandatory fields</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-output-with-mandatory-fields/m-p/3770627#M907323</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi again, Vipul.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My suggestion is: let both field NOT mandatory, and check the displayed field. Example, if the field 1 is not locked, check it.&lt;/P&gt;&lt;P&gt;Like that:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
AT SELECTION-SCREEN OUTPUT.

  LOOP AT SCREEN.
    IF p_aspt IS NOT INITIAL.

      IF screen-group1 = 'SG2'.
        screen-input    = 0.
      ENDIF.

    ELSEIF p_ocfd IS NOT INITIAL.

      IF screen-group1 = 'SG1'.
        screen-input    = 0.
      ENDIF.

    ENDIF.

    MODIFY SCREEN.
  ENDLOOP.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And right after, you can check if the displayed field is not empty:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
IF p_aspt IS NOT INITIAL.

  IF s_crd-low  IS INITIAL AND
   s_crd-high IS INITIAL.
MESSAGE s000(zclass) WITH 'Fill in all required fields' 
DISPLAY LIKE 'E'.
  LEAVE LIST-PROCESSING AND RETURN TO SCREEN 0.
  ENDIF.

ELSEIF p_ocfd IS NOT INITIAL.

    IF s_schd-low  IS INITIAL AND
     s_schd-high IS INITIAL.
  MESSAGE s000(zclass) WITH 'Fill in all required fields'
  DISPLAY LIKE 'E'.
  LEAVE LIST-PROCESSING AND RETURN TO SCREEN 0.
  ENDIF.

ENDIF.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This will be like if the field which is displayed can't be empty, cause otherwise, the program will stop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope it helps,&lt;/P&gt;&lt;P&gt;Brian Gonsales.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 May 2008 21:03:06 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-output-with-mandatory-fields/m-p/3770627#M907323</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-06T21:03:06Z</dc:date>
    </item>
    <item>
      <title>Re: Selection-screen output with mandatory fields</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-output-with-mandatory-fields/m-p/3770628#M907324</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi&lt;/P&gt;&lt;P&gt;Try this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM selection_screen_modifications.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOOP AT SCREEN.&lt;/P&gt;&lt;P&gt;IF screen-group1 = 'SG2' and p_aspt = 'X'..&lt;/P&gt;&lt;P&gt;screen-input = 1.&lt;/P&gt;&lt;P&gt;screen-reuiered = 1.&lt;/P&gt;&lt;P&gt;elseif IF screen-group1 = 'SG1' and p_ocfd = 'X'.&lt;/P&gt;&lt;P&gt;screen-input = 1.&lt;/P&gt;&lt;P&gt;screen-reuiered = 1.&lt;/P&gt;&lt;P&gt;else.&lt;/P&gt;&lt;P&gt;screen-input = 0.&lt;/P&gt;&lt;P&gt;screen-reuiered = 0.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;MODIFY SCREEN.&lt;/P&gt;&lt;P&gt;ENDLOOP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDFORM.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 07 May 2008 08:13:36 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-output-with-mandatory-fields/m-p/3770628#M907324</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-07T08:13:36Z</dc:date>
    </item>
    <item>
      <title>Re: Selection-screen output with mandatory fields</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-output-with-mandatory-fields/m-p/3770629#M907325</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you all.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The answers were helpful to some extent but the only way I could solve the problem was by putting some default values in the mandatory fields. THose were date fields so I defaulted the current date.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Brian's answer was very helpful. It could have worked but since I am using SAP 4.6C. display like 'E' did not work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you very much.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 07 May 2008 12:44:44 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-output-with-mandatory-fields/m-p/3770629#M907325</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-07T12:44:44Z</dc:date>
    </item>
    <item>
      <title>Re: Selection-screen output with mandatory fields</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-output-with-mandatory-fields/m-p/3770630#M907326</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This problem was solved by putting a default value in the mandatory fields.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 07 May 2008 12:45:25 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-output-with-mandatory-fields/m-p/3770630#M907326</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-07T12:45:25Z</dc:date>
    </item>
  </channel>
</rss>

