<?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: WRITE issue to display in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/write-issue-to-display/m-p/12594354#M2010484</link>
    <description>&lt;P&gt;Hi &lt;/P&gt;&lt;P&gt;You can modify your program as below: &lt;/P&gt;&lt;P&gt;This will smoothly gives message even though they enter 0.&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;  PARAMETERS: p_angle1 TYPE i ,     "Remove obligatory
              p_angle2 TYPE i .&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;In case section, add the wrapper IF statement as below&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;    WHEN 'FC1'.
     
     IF ( p_angle1 &amp;gt; 0 and p_angle2 &amp;gt; 0 )                "&amp;lt;=====Add a global if statement. 

      v_sum_angle = p_angle1 + p_angle2.
      v_angle3 = 180 - v_sum_angle.

      IF p_angle1 &amp;gt; 178.
        message  'Number not allow' type 'E'.
      ELSE.
       write:  'L angle est de:',v_angle3 LEFT-JUSTIFIED,'degré' LEFT-JUSTIFIED.
      ENDIF.
    ELSE.                                               "&amp;lt;=====Add a global if statement. 
      message  'Check your input' type 'S'.
    ENDIF.                                              "&amp;lt;=====Add a global if statement.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Venkat&lt;/P&gt;</description>
    <pubDate>Mon, 22 Aug 2022 06:54:19 GMT</pubDate>
    <dc:creator>venkateswaran_k</dc:creator>
    <dc:date>2022-08-22T06:54:19Z</dc:date>
    <item>
      <title>WRITE issue to display</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/write-issue-to-display/m-p/12594352#M2010482</link>
      <description>&lt;P&gt;I wrote a program which calulate the third angle of a triangle after the user provide the First Two one.&lt;/P&gt;
  &lt;P&gt;I create a button to made the calculation, but it didn't display it... &lt;/P&gt;
  &lt;P&gt;how to forbid the user to put 0 on any field...of course the "Obligatory" do the job, but if it wasn't one how to do that.&lt;/P&gt;
  &lt;P&gt;and in the same time i put a button to leave the program even if the field are empty...&lt;/P&gt;
  &lt;P&gt;Thanks.&lt;/P&gt;
  &lt;PRE&gt;&lt;CODE&gt;DATA: v_angle3    TYPE i,
      v_sum_angle TYPE i.


SELECTION-SCREEN BEGIN OF BLOCK blk1 WITH FRAME TITLE TEXT-001.

  PARAMETERS: p_angle1 TYPE i OBLIGATORY,
              p_angle2 TYPE i OBLIGATORY.
  SELECTION-SCREEN SKIP 2.
  SELECTION-SCREEN PUSHBUTTON 38(9) bt1 USER-COMMAND fc1.
  SELECTION-SCREEN PUSHBUTTON 26(9) bt2 USER-COMMAND fc2.
  SELECTION-SCREEN SKIP 2.
  SELECTION-SCREEN PUSHBUTTON 26(9) bt3 USER-COMMAND fc3.

SELECTION-SCREEN END OF BLOCK blk1.

INITIALIZATION.
  bt1 = 'Calculer'.
  bt2 = 'Reset'.
  bt3 = 'Sortir'.

AT SELECTION-SCREEN.

  CASE sy-ucomm.

    WHEN 'FC1'.

      v_sum_angle = p_angle1 + p_angle2.
      v_angle3 = 180 - v_sum_angle.


      IF p_angle1 &amp;gt; 178.
        message  'Number not allow' type 'E'.
      ELSE.
       write:  'L angle est de:',v_angle3 LEFT-JUSTIFIED,'degré' LEFT-JUSTIFIED.
      ENDIF.

    WHEN 'FC2'.

      CLEAR : p_angle1,
              p_angle2.

      MESSAGE 'Les Champs ont été effacés' TYPE 'I'.
    WHEN 'FC3'.

      LEAVE PROGRAM.

  ENDCASE.&lt;BR /&gt;&lt;/CODE&gt;&lt;/PRE&gt;
  &lt;P&gt;Thanks you folks to read so far here you are a love...&lt;/P&gt;</description>
      <pubDate>Sun, 21 Aug 2022 21:32:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/write-issue-to-display/m-p/12594352#M2010482</guid>
      <dc:creator>d4xtian</dc:creator>
      <dc:date>2022-08-21T21:32:59Z</dc:date>
    </item>
    <item>
      <title>Re: WRITE issue to display</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/write-issue-to-display/m-p/12594353#M2010483</link>
      <description>&lt;P&gt;Remove OBLIGATORY and do:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;IF p_angle1 = 0.
  MESSAGE 'p_angle1 is obligatory' TYPE 'E'.
ENDIF.&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 22 Aug 2022 06:41:24 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/write-issue-to-display/m-p/12594353#M2010483</guid>
      <dc:creator>Sandra_Rossi</dc:creator>
      <dc:date>2022-08-22T06:41:24Z</dc:date>
    </item>
    <item>
      <title>Re: WRITE issue to display</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/write-issue-to-display/m-p/12594354#M2010484</link>
      <description>&lt;P&gt;Hi &lt;/P&gt;&lt;P&gt;You can modify your program as below: &lt;/P&gt;&lt;P&gt;This will smoothly gives message even though they enter 0.&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;  PARAMETERS: p_angle1 TYPE i ,     "Remove obligatory
              p_angle2 TYPE i .&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;In case section, add the wrapper IF statement as below&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;    WHEN 'FC1'.
     
     IF ( p_angle1 &amp;gt; 0 and p_angle2 &amp;gt; 0 )                "&amp;lt;=====Add a global if statement. 

      v_sum_angle = p_angle1 + p_angle2.
      v_angle3 = 180 - v_sum_angle.

      IF p_angle1 &amp;gt; 178.
        message  'Number not allow' type 'E'.
      ELSE.
       write:  'L angle est de:',v_angle3 LEFT-JUSTIFIED,'degré' LEFT-JUSTIFIED.
      ENDIF.
    ELSE.                                               "&amp;lt;=====Add a global if statement. 
      message  'Check your input' type 'S'.
    ENDIF.                                              "&amp;lt;=====Add a global if statement.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Venkat&lt;/P&gt;</description>
      <pubDate>Mon, 22 Aug 2022 06:54:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/write-issue-to-display/m-p/12594354#M2010484</guid>
      <dc:creator>venkateswaran_k</dc:creator>
      <dc:date>2022-08-22T06:54:19Z</dc:date>
    </item>
    <item>
      <title>Re: WRITE issue to display</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/write-issue-to-display/m-p/12594355#M2010485</link>
      <description>&lt;P&gt;Thanks you for the global If Statement.&lt;/P&gt;&lt;P&gt;Write, don't display anything ? i don't know why &lt;/P&gt;</description>
      <pubDate>Mon, 22 Aug 2022 08:15:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/write-issue-to-display/m-p/12594355#M2010485</guid>
      <dc:creator>d4xtian</dc:creator>
      <dc:date>2022-08-22T08:15:13Z</dc:date>
    </item>
    <item>
      <title>Re: WRITE issue to display</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/write-issue-to-display/m-p/12594356#M2010486</link>
      <description>&lt;P&gt;&lt;SPAN class="mention-scrubbed"&gt;fotso&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;Write will be displayed after completion of the program.&lt;/P&gt;&lt;P&gt;So use message statement.&lt;/P&gt;</description>
      <pubDate>Mon, 22 Aug 2022 08:21:21 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/write-issue-to-display/m-p/12594356#M2010486</guid>
      <dc:creator>venkateswaran_k</dc:creator>
      <dc:date>2022-08-22T08:21:21Z</dc:date>
    </item>
    <item>
      <title>Re: WRITE issue to display</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/write-issue-to-display/m-p/12594357#M2010487</link>
      <description>&lt;P&gt;I have another question about the following:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;message  'Check your input' type 'S' DISPLAY LIKE 'S'&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Why use "DISPLAY LIKE 'S' " in this case as TYPE is already 'S' ?&lt;BR /&gt;&lt;BR /&gt;I know that the difference is the type of icon which ll display ?&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Mon, 22 Aug 2022 08:29:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/write-issue-to-display/m-p/12594357#M2010487</guid>
      <dc:creator>d4xtian</dc:creator>
      <dc:date>2022-08-22T08:29:55Z</dc:date>
    </item>
    <item>
      <title>Re: WRITE issue to display</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/write-issue-to-display/m-p/12594358#M2010488</link>
      <description>&lt;P&gt;&lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt; Display like is optional. Not necessary.. I removed it.&lt;/P&gt;</description>
      <pubDate>Mon, 22 Aug 2022 08:40:27 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/write-issue-to-display/m-p/12594358#M2010488</guid>
      <dc:creator>venkateswaran_k</dc:creator>
      <dc:date>2022-08-22T08:40:27Z</dc:date>
    </item>
    <item>
      <title>Re: WRITE issue to display</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/write-issue-to-display/m-p/12594359#M2010489</link>
      <description>&lt;P&gt;&lt;SPAN class="mention-scrubbed"&gt;venkateswaran.k&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;You can edit your answer too, to not confuse future visitors &lt;span class="lia-unicode-emoji" title=":winking_face:"&gt;😉&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 22 Aug 2022 08:48:54 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/write-issue-to-display/m-p/12594359#M2010489</guid>
      <dc:creator>Sandra_Rossi</dc:creator>
      <dc:date>2022-08-22T08:48:54Z</dc:date>
    </item>
    <item>
      <title>Re: WRITE issue to display</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/write-issue-to-display/m-p/12594360#M2010490</link>
      <description>&lt;P&gt;It could help newbie..&lt;/P&gt;&lt;P&gt;This is how you display message with parameters&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;message i002(ZPOANGLE) with v_angle3.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Before you need to create a Message Class, by going to T-code SE91 Message Maintenance&lt;/P&gt;</description>
      <pubDate>Mon, 22 Aug 2022 12:39:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/write-issue-to-display/m-p/12594360#M2010490</guid>
      <dc:creator>d4xtian</dc:creator>
      <dc:date>2022-08-22T12:39:11Z</dc:date>
    </item>
  </channel>
</rss>

