<?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: Date Field in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-field/m-p/1012253#M79168</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;Try This - &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data: v_date(8) type c.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;write sy-datum to v_date.&lt;/P&gt;&lt;P&gt;concatenate v_date&lt;EM&gt;0(2) '/' v_date&lt;/EM&gt;2(2) '/' v_date+6(2) into v_date.&lt;/P&gt;&lt;P&gt;write:/ v_date.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 22 Sep 2005 08:13:56 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2005-09-22T08:13:56Z</dc:date>
    <item>
      <title>Date Field</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-field/m-p/1012247#M79162</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hai.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In my report i have date fields as inputfields, i am using 8 char type to print date. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data: t_date(8) type c.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;user have to enter date in this format MM/DD/YY. But its a character field user can enter any type. I am validating this field using READ LINE option but to validate one date field. I am giving more than 20 conditions.  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there any possibility validating input field in screen it self or what is the best way to display date field as input field and date format should be in above format. And I will have more than 100 date input fields depends on user selection in selection screen..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Could somebody tell best way to do this..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Sunil&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 20 Sep 2005 03:37:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-field/m-p/1012247#M79162</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-09-20T03:37:51Z</dc:date>
    </item>
    <item>
      <title>Re: Date Field</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-field/m-p/1012248#M79163</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Declare your date fields in the selection screen as SY-DATUM. This way the users can enter the date in the format they want(controlled by their user profile). Internally in your program, you will have the date in internal format YYYYMMDD which will help you do all kinds of date validations and selections. Then when you output the date, you can use the options for WRITE statement like EDIT MASK. Check the WRITE help.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Srinivas&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 20 Sep 2005 03:46:50 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-field/m-p/1012248#M79163</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-09-20T03:46:50Z</dc:date>
    </item>
    <item>
      <title>Re: Date Field</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-field/m-p/1012249#M79164</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;for the input fields you define type as D, then the date will display as standard format.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;at the time of processing the date you change the format into mm/dd/yy. by using offset and concatenate method&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data: p_date type d,&lt;/P&gt;&lt;P&gt;      p_disp(8) type c,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;then p_date will be 20051231&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;concatenate p_date&lt;EM&gt;2(2) '/' p_date&lt;/EM&gt;4(2) '/' p_date+6(2)&lt;/P&gt;&lt;P&gt;            into p_disp.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;the validatation of the date is not possible by doing manually.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;cheers,&lt;/P&gt;&lt;P&gt;sasi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 20 Sep 2005 03:53:16 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-field/m-p/1012249#M79164</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-09-20T03:53:16Z</dc:date>
    </item>
    <item>
      <title>Re: Date Field</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-field/m-p/1012250#M79165</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;Declare the date field in selection screen ad sy-datum it will automatically validate the dates that user enters no need to do any validation.&lt;/P&gt;&lt;P&gt;If u want to do so u can validate in&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;AT SELECTION SCREEN ON s_date.
 perform validate_date.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps.&lt;/P&gt;&lt;P&gt;Kindly reward points and close the thread.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Sep 2005 03:46:42 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-field/m-p/1012250#M79165</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-09-21T03:46:42Z</dc:date>
    </item>
    <item>
      <title>Re: Date Field</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-field/m-p/1012251#M79166</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;there is a function module to check if a given date is valid....its DATE_CHECK_PLAUSIBILITY...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;see if it helps you....of course declaring as sy-datum will still be a better option...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;rgds,&lt;/P&gt;&lt;P&gt;PJ&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Sep 2005 04:33:17 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-field/m-p/1012251#M79166</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-09-21T04:33:17Z</dc:date>
    </item>
    <item>
      <title>Re: Date Field</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-field/m-p/1012252#M79167</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sunil,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    If your requirement is to enter date in the format MM/DD/YY, then which century will you consider for YY? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    After confirming the century, format the date into 'DD.MM.YYYY' format and then pass it to the FM, 'DATE_CHECK_PLAUSIBILITY', which will check whether the given date is valid or not? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   You can write this in a subroutine and you can call the same for all the date fields...&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;Phani&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Sep 2005 05:14:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-field/m-p/1012252#M79167</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-09-21T05:14:52Z</dc:date>
    </item>
    <item>
      <title>Re: Date Field</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-field/m-p/1012253#M79168</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;Try This - &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data: v_date(8) type c.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;write sy-datum to v_date.&lt;/P&gt;&lt;P&gt;concatenate v_date&lt;EM&gt;0(2) '/' v_date&lt;/EM&gt;2(2) '/' v_date+6(2) into v_date.&lt;/P&gt;&lt;P&gt;write:/ v_date.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 22 Sep 2005 08:13:56 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-field/m-p/1012253#M79168</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-09-22T08:13:56Z</dc:date>
    </item>
  </channel>
</rss>

