<?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 data validation problem in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-data-validation-problem/m-p/8182178#M1624391</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;In program RFITEMGL, there is a function module called BUKRS_AUTHORITY_CHECK which is being used for authority check.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;System is checking SY-COMM value for when 'ONLI' or 'PRIN' or 'INIT' or space.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please have a look into the same.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Shiva&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 15 Sep 2011 00:24:13 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2011-09-15T00:24:13Z</dc:date>
    <item>
      <title>Selection screen data validation problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-data-validation-problem/m-p/8182177#M1624390</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello all,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Transaction FBL3N has an authority check on company.  If the user enters a company for which they have no authority, a message displays and they can then exclude that company.  The following steps can be repeated as many times as are required to ensure that all selection-screen values can be used.  The program, RFITEMGL, is doing all of the authorization using the code of the logical database that is part of the program.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I added the following logic in my program, which works fine, except when the entered values fail the authority check, I can't get off of screen 1000 and get to the sub-screen to exclude the unauthorized values unless I first change the range on screen 1000.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For an example:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If I enter range '100 ' through '900 ', and there is an unauthorized company, '200' in that range,  I can't add '200' as an excluded value without first changing the range to '100 ' to ' 199 ' on screen 1000.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any thoughts on a solution?  I tried looking at the logical database code without much success.&lt;/P&gt;&lt;P&gt;*&lt;/P&gt;&lt;P&gt; at selection-screen on s_bukrs.&lt;/P&gt;&lt;P&gt;*&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;check if person entering company has authority&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;*&lt;/P&gt;&lt;P&gt;data: i_t001 type table of t001.&lt;/P&gt;&lt;P&gt;data: w_t001 type          t001.&lt;/P&gt;&lt;P&gt;*&lt;/P&gt;&lt;P&gt;*&lt;/P&gt;&lt;P&gt;  select * from t001&lt;/P&gt;&lt;P&gt;           into table i_t001&lt;/P&gt;&lt;P&gt;           where bukrs in s_bukrs.&lt;/P&gt;&lt;P&gt;*&lt;/P&gt;&lt;P&gt;  loop at i_t001 into w_t001.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    authority-check object 'F_BKPF_BUK'&lt;/P&gt;&lt;P&gt;                id 'BUKRS' field w_t001-bukrs&lt;/P&gt;&lt;P&gt;                id 'ACTVT' field '03'.&lt;/P&gt;&lt;P&gt;*&lt;/P&gt;&lt;P&gt;    if sy-subrc ne 0.&lt;/P&gt;&lt;P&gt;      message e000(zf) with 'Company'&lt;/P&gt;&lt;P&gt;                          w_t001-bukrs&lt;/P&gt;&lt;P&gt;                          'not authorized'.&lt;/P&gt;&lt;P&gt;    endif.&lt;/P&gt;&lt;P&gt;*&lt;/P&gt;&lt;P&gt;  endloop.&lt;/P&gt;&lt;P&gt;*&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Bruce&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Sep 2011 23:38:36 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-data-validation-problem/m-p/8182177#M1624390</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-09-14T23:38:36Z</dc:date>
    </item>
    <item>
      <title>Re: Selection screen data validation problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-data-validation-problem/m-p/8182178#M1624391</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;In program RFITEMGL, there is a function module called BUKRS_AUTHORITY_CHECK which is being used for authority check.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;System is checking SY-COMM value for when 'ONLI' or 'PRIN' or 'INIT' or space.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please have a look into the same.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Shiva&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 Sep 2011 00:24:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-data-validation-problem/m-p/8182178#M1624391</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-09-15T00:24:13Z</dc:date>
    </item>
    <item>
      <title>Re: Selection screen data validation problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-data-validation-problem/m-p/8182179#M1624392</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;Yes this is normal way as you entered wrong value in s_bukrs unless and until you change that you cannot proceed further.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;instead of at selection-screen on s_bukrs.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;use at selection-screen.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if s_bukrs is not initial.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;do processing .,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and display info message'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;or ., instead of error message  use dispaly like 'E'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;like.,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;at selection-screen on s_bukrs.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;check authority.,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;MESSAGE 'You are not Authorized to use the Company Code' type 'S' display like 'E'.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;hope this helps you,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; Regards.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 Sep 2011 04:45:24 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-data-validation-problem/m-p/8182179#M1624392</guid>
      <dc:creator>Kiran_Valluru</dc:creator>
      <dc:date>2011-09-15T04:45:24Z</dc:date>
    </item>
    <item>
      <title>Re: Selection screen data validation problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-data-validation-problem/m-p/8182180#M1624393</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Shiva ,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for the answer.  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Bruce&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 Sep 2011 17:04:54 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen-data-validation-problem/m-p/8182180#M1624393</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-09-15T17:04:54Z</dc:date>
    </item>
  </channel>
</rss>

