<?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 Logic based on Date on Selection-Screen in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/logic-based-on-date-on-selection-screen/m-p/2649707#M610720</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear friends,&lt;/P&gt;&lt;P&gt;I've been writing a report in which I have the date field on selection-screen. By default I have been displaying the system date on the selection-screen.&lt;/P&gt;&lt;P&gt;The reqiurement is that the user cannot execute the code for a date in past (less than the system date) or cannot give a date less than the sytem date&lt;/P&gt;&lt;P&gt;but can execute the same for a date in future (greater than the system date).&lt;/P&gt;&lt;P&gt;Can any one give me the logic for the same.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Alok.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 17 Aug 2007 06:29:31 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-08-17T06:29:31Z</dc:date>
    <item>
      <title>Logic based on Date on Selection-Screen</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/logic-based-on-date-on-selection-screen/m-p/2649707#M610720</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear friends,&lt;/P&gt;&lt;P&gt;I've been writing a report in which I have the date field on selection-screen. By default I have been displaying the system date on the selection-screen.&lt;/P&gt;&lt;P&gt;The reqiurement is that the user cannot execute the code for a date in past (less than the system date) or cannot give a date less than the sytem date&lt;/P&gt;&lt;P&gt;but can execute the same for a date in future (greater than the system date).&lt;/P&gt;&lt;P&gt;Can any one give me the logic for the same.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Alok.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Aug 2007 06:29:31 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/logic-based-on-date-on-selection-screen/m-p/2649707#M610720</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-17T06:29:31Z</dc:date>
    </item>
    <item>
      <title>Re: Logic based on Date on Selection-Screen</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/logic-based-on-date-on-selection-screen/m-p/2649708#M610721</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;This is the code for u.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PARAMETERS : P_DATE TYPE SY-DATUM .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;INITIALIZATION.&lt;/P&gt;&lt;P&gt;  MOVE SY-DATUM TO P_dATE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;AT SELECTION-SCREEN ON P_DATE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   IF P_DATE &amp;lt; SY-DATUM.&lt;/P&gt;&lt;P&gt;              MESSAGE 'Entered date cannot be in Past' Type 'E'.&lt;/P&gt;&lt;P&gt;**Raise any message that u created otherwise  &lt;/P&gt;&lt;P&gt;   ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Reward if Helpful&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Aug 2007 06:32:17 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/logic-based-on-date-on-selection-screen/m-p/2649708#M610721</guid>
      <dc:creator>varma_narayana</dc:creator>
      <dc:date>2007-08-17T06:32:17Z</dc:date>
    </item>
    <item>
      <title>Re: Logic based on Date on Selection-Screen</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/logic-based-on-date-on-selection-screen/m-p/2649709#M610722</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;write the logic in the event at selection-screen on &amp;lt;date field&amp;gt;&lt;/P&gt;&lt;P&gt;if p_date &amp;lt; sy-datum.&lt;/P&gt;&lt;P&gt;  message e000 with 'enter a data in the future'.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Reward points for useful Answers&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Anji&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Aug 2007 06:33:36 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/logic-based-on-date-on-selection-screen/m-p/2649709#M610722</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-17T06:33:36Z</dc:date>
    </item>
    <item>
      <title>Re: Logic based on Date on Selection-Screen</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/logic-based-on-date-on-selection-screen/m-p/2649710#M610723</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;AT SELECTION-SCREEN.&lt;/P&gt;&lt;P&gt;    IF s_date LE sy-datum.&lt;/P&gt;&lt;P&gt;       MESSAGE e001(error) WITH 'Date should be greater than system date'.&lt;/P&gt;&lt;P&gt;      ENDIF.&lt;/P&gt;&lt;P&gt;    ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;try using the above code.&lt;/P&gt;&lt;P&gt;reward if useful&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Aug 2007 06:34:04 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/logic-based-on-date-on-selection-screen/m-p/2649710#M610723</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-17T06:34:04Z</dc:date>
    </item>
    <item>
      <title>Re: Logic based on Date on Selection-Screen</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/logic-based-on-date-on-selection-screen/m-p/2649711#M610724</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Report Z10_SB_DATE MESSAGE-ID Z10SBAN.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;AT SELECTION-SCREEN.&lt;/P&gt;&lt;P&gt;if d_date &amp;lt; sy-datum.&lt;/P&gt;&lt;P&gt;message e001 with d_date.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What this will do is that if the date(d_date) entered is less than current date,&lt;/P&gt;&lt;P&gt;an error message 001 (from message id z10sban) will be flashed in re&lt;/P&gt;&lt;P&gt;at the bottom and the execution will terminate then and there it self.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Aug 2007 06:34:05 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/logic-based-on-date-on-selection-screen/m-p/2649711#M610724</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-17T06:34:05Z</dc:date>
    </item>
    <item>
      <title>Re: Logic based on Date on Selection-Screen</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/logic-based-on-date-on-selection-screen/m-p/2649712#M610725</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Alok,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if s_datum &amp;gt; sy-datum.&lt;/P&gt;&lt;P&gt;perform getdata.&lt;/P&gt;&lt;P&gt;else.&lt;/P&gt;&lt;P&gt;MESSAGE e034(zal) WITH s_datum.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the message class zal give an message for 034.&lt;/P&gt;&lt;P&gt;In the subroutine getdata write the code.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;K.Kiran.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: &lt;/P&gt;&lt;P&gt;        Kiran K&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Aug 2007 06:35:47 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/logic-based-on-date-on-selection-screen/m-p/2649712#M610725</guid>
      <dc:creator>kiran_k8</dc:creator>
      <dc:date>2007-08-17T06:35:47Z</dc:date>
    </item>
    <item>
      <title>Re: Logic based on Date on Selection-Screen</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/logic-based-on-date-on-selection-screen/m-p/2649713#M610726</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;parameters p_date like sy-datum  default sy-datum.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;at selection-screen.&lt;/P&gt;&lt;P&gt; if p_date &amp;lt; sy-datum.&lt;/P&gt;&lt;P&gt;   message w003(zf).&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Aug 2007 06:39:02 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/logic-based-on-date-on-selection-screen/m-p/2649713#M610726</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-17T06:39:02Z</dc:date>
    </item>
  </channel>
</rss>

