<?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: How do I add validation to a system-generated Selection Screen? in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-do-i-add-validation-to-a-system-generated-selection-screen/m-p/1186299#M127255</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Under the AT SELECTION-SCREEN Event, just before doing your check, add this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;CHECK SY-UCOMM = 'ONLI'.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rich Heilman&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 22 Feb 2006 15:52:06 GMT</pubDate>
    <dc:creator>RichHeilman</dc:creator>
    <dc:date>2006-02-22T15:52:06Z</dc:date>
    <item>
      <title>How do I add validation to a system-generated Selection Screen?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-do-i-add-validation-to-a-system-generated-selection-screen/m-p/1186298#M127254</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;As HR ABAPers know, using the Logical Database approach (I'm using PNPCE) gives you a system-generated Selection Screen.  Part of the specs I have for this report involves making sure that the begin and end dates for the period selected are for a two-week period.  If not, I should display an error message until the user enters a period such that the period (pn-begda and pn-endda) reflect a two-week period.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The code for the validation is easy enough, and I put it in the AT SELECTION-SCREEN event.  But here's the problem -- the code fires every time the user clicks the "Reporting Period" drop-down box, never giving the user a chance to specify a two-week period.  It fires because pn-begda and pn-endda are still all zeroes.  Even if I select "Other Period" from the drop-down list, the text boxes to allow me to specify the begin and end dates don't appear.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I've been working on this for quite a while, trying all kinds of things, but I'm spinning my wheels now.  I just want that check to happen when the user clicks the Execute button on the Selection Screen, not when he/she is still trying to enter criteria.  I'm thinking screen field validation for a system-generated Selection Screen has to be a pretty common thing, and there must be a good solution out there.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any ideas?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Feb 2006 15:47:53 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-do-i-add-validation-to-a-system-generated-selection-screen/m-p/1186298#M127254</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-02-22T15:47:53Z</dc:date>
    </item>
    <item>
      <title>Re: How do I add validation to a system-generated Selection Screen?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-do-i-add-validation-to-a-system-generated-selection-screen/m-p/1186299#M127255</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Under the AT SELECTION-SCREEN Event, just before doing your check, add this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;CHECK SY-UCOMM = 'ONLI'.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rich Heilman&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Feb 2006 15:52:06 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-do-i-add-validation-to-a-system-generated-selection-screen/m-p/1186299#M127255</guid>
      <dc:creator>RichHeilman</dc:creator>
      <dc:date>2006-02-22T15:52:06Z</dc:date>
    </item>
    <item>
      <title>Re: How do I add validation to a system-generated Selection Screen?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-do-i-add-validation-to-a-system-generated-selection-screen/m-p/1186300#M127256</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Could you not initialize pn-begda and pn-endda at the INITIALIZATION event to something like today and two weeks from today?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Feb 2006 15:54:06 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-do-i-add-validation-to-a-system-generated-selection-screen/m-p/1186300#M127256</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-02-22T15:54:06Z</dc:date>
    </item>
    <item>
      <title>Re: How do I add validation to a system-generated Selection Screen?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-do-i-add-validation-to-a-system-generated-selection-screen/m-p/1186301#M127257</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Rich,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Absolutely beautiful -- that's exactly what I needed to learn.  Thank you so much.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob, I thought about that.  I even proposed to the users that I could default in a two-week range beginning with today, exactly as you suggested, but they didn't want that.  They felt that this report would more often than not be run to reflect data from two-week periods not necessarily starting today.  Still thought it was a good idea, but that's their call. &lt;SUP&gt;_&lt;/SUP&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Again, thanks Rich.  Points awarded.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Feb 2006 16:00:09 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-do-i-add-validation-to-a-system-generated-selection-screen/m-p/1186301#M127257</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-02-22T16:00:09Z</dc:date>
    </item>
    <item>
      <title>Re: How do I add validation to a system-generated Selection Screen?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-do-i-add-validation-to-a-system-generated-selection-screen/m-p/1186302#M127258</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Glad to help.  &lt;SPAN __jive_emoticon_name="happy"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;RIch Heilman&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Feb 2006 16:04:12 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-do-i-add-validation-to-a-system-generated-selection-screen/m-p/1186302#M127258</guid>
      <dc:creator>RichHeilman</dc:creator>
      <dc:date>2006-02-22T16:04:12Z</dc:date>
    </item>
  </channel>
</rss>

