<?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: Condition inside a search help exit in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/condition-inside-a-search-help-exit/m-p/5976585#M1340158</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Nikhil,&lt;/P&gt;&lt;P&gt;No I cannot hard code the screen number because different screens will be calling the same search help exit. Based the on screen which is calling, I want to restrict the values.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Priyanka&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 21 Aug 2009 10:37:39 GMT</pubDate>
    <dc:creator>PriyankaAgarwal</dc:creator>
    <dc:date>2009-08-21T10:37:39Z</dc:date>
    <item>
      <title>Condition inside a search help exit</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/condition-inside-a-search-help-exit/m-p/5976583#M1340156</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Colleagues,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have implemented a search help exit for restricting values of a domain.The selection method used in search help  is DD07T.&lt;/P&gt;&lt;P&gt;The values are getting restricted properly.&lt;/P&gt;&lt;P&gt;Now,I need to restrict the values based on some condition(screen or view name) which uses this search help.I see the sy-tcode returns sm30 and sy-dynnr returns 0600. &lt;/P&gt;&lt;P&gt;When the search help exit is called the sy-dynnr changes to the screen 0600 of the program SAPMSHLP. But I want to check based on the sy-dynnr of the calling screen/view.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have written the following code but it doesnt work since the sy-dynnr changes to 0600 as soon as the search help exit gets called.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  TYPES: my_type TYPE dd07t.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  DATA: BEGIN OF ls_record.&lt;/P&gt;&lt;P&gt;          INCLUDE STRUCTURE seahlpres.&lt;/P&gt;&lt;P&gt;  DATA: END OF ls_record.&lt;/P&gt;&lt;P&gt;  FIELD-SYMBOLS: &amp;lt;fs&amp;gt; TYPE my_type.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CHECK callcontrol-step = 'DISP'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  IF sy-dynnr = '0800'.&lt;/P&gt;&lt;P&gt;    LOOP AT record_tab ASSIGNING &amp;lt;fs&amp;gt; CASTING.&lt;/P&gt;&lt;P&gt;      IF &amp;lt;fs&amp;gt;-domvalue_l &amp;lt;= '10'.&lt;/P&gt;&lt;P&gt;        DELETE record_tab INDEX sy-tabix.&lt;/P&gt;&lt;P&gt;      ENDIF.&lt;/P&gt;&lt;P&gt;    ENDLOOP.&lt;/P&gt;&lt;P&gt;  ELSEIF sy-dynnr = '0400'.&lt;/P&gt;&lt;P&gt;  LOOP AT record_tab ASSIGNING &amp;lt;fs&amp;gt; CASTING.&lt;/P&gt;&lt;P&gt;    IF &amp;lt;fs&amp;gt;-domvalue_l  &amp;gt; '10'.&lt;/P&gt;&lt;P&gt;      DELETE record_tab INDEX sy-tabix.&lt;/P&gt;&lt;P&gt;    ENDIF.&lt;/P&gt;&lt;P&gt;  ENDLOOP.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Could anyone tell me how can i check. Viewname and screen number is the only way. But in search help exit i dont get the correct screen number or transaction code.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Priyanka&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Aug 2009 09:59:09 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/condition-inside-a-search-help-exit/m-p/5976583#M1340156</guid>
      <dc:creator>PriyankaAgarwal</dc:creator>
      <dc:date>2009-08-21T09:59:09Z</dc:date>
    </item>
    <item>
      <title>Re: Condition inside a search help exit</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/condition-inside-a-search-help-exit/m-p/5976584#M1340157</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;null&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Nikhil Poojari on Aug 21, 2009 12:17 PM&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Nikhil Poojari on Aug 21, 2009 12:17 PM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Aug 2009 10:16:50 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/condition-inside-a-search-help-exit/m-p/5976584#M1340157</guid>
      <dc:creator>nikhilkup</dc:creator>
      <dc:date>2009-08-21T10:16:50Z</dc:date>
    </item>
    <item>
      <title>Re: Condition inside a search help exit</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/condition-inside-a-search-help-exit/m-p/5976585#M1340158</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Nikhil,&lt;/P&gt;&lt;P&gt;No I cannot hard code the screen number because different screens will be calling the same search help exit. Based the on screen which is calling, I want to restrict the values.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Priyanka&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Aug 2009 10:37:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/condition-inside-a-search-help-exit/m-p/5976585#M1340158</guid>
      <dc:creator>PriyankaAgarwal</dc:creator>
      <dc:date>2009-08-21T10:37:39Z</dc:date>
    </item>
  </channel>
</rss>

