<?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: Dynamic button in Dynpro in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-button-in-dynpro/m-p/2789953#M650778</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 the screen painter go to the attributes of that push button.select the check box &amp;lt;b&amp;gt;WITH ICON&amp;lt;/b&amp;gt; and&lt;/P&gt;&lt;P&gt;in the lower tab strip(program tab)&lt;/P&gt;&lt;P&gt;select the check box &amp;lt;b&amp;gt;OUTPUT FIELD&amp;lt;/b&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;now in the pbo of the screen write like below.&lt;/P&gt;&lt;P&gt;data:&amp;lt;button name&amp;gt;(30).&lt;/P&gt;&lt;P&gt;data:but_name(30).&lt;/P&gt;&lt;P&gt;concatenate &amp;lt;icon_name&amp;gt; &amp;lt;icon text&amp;gt; into but_name sepatared by space.&lt;/P&gt;&lt;P&gt;&amp;lt;button name&amp;gt; = but_name.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;rgds,&lt;/P&gt;&lt;P&gt;bharat.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 13 Sep 2007 11:51:08 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-09-13T11:51:08Z</dc:date>
    <item>
      <title>Dynamic button in Dynpro</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-button-in-dynpro/m-p/2789950#M650775</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;I've designed a Dynpro with some buttons whose icon has to change dynamically. For example, if a process goes ok it should be ICON_OKAY, or if it goes ko, ICON_CANCEL.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Does anyone know how to do this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Carles&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 Sep 2007 11:34:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-button-in-dynpro/m-p/2789950#M650775</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-13T11:34:11Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic button in Dynpro</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-button-in-dynpro/m-p/2789951#M650776</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;Check the FM 'ICON_CREATE', maybe it could be useful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 Sep 2007 11:38:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-button-in-dynpro/m-p/2789951#M650776</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-13T11:38:48Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic button in Dynpro</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-button-in-dynpro/m-p/2789952#M650777</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Carles,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please refer the standard code "DEMO_DYNPRO_STATUS_ICONS" in se38&lt;/P&gt;&lt;P&gt;on click of a button it is changing the status&lt;/P&gt;&lt;P&gt;here..in your case..with the click of different buttons we get different sy-ucomms&lt;/P&gt;&lt;P&gt;and based on value of sy-ucomm we can change the icon&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Simple steps&lt;/P&gt;&lt;P&gt;***********************&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;When 'OK'.&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'ICON_CREATE'&lt;/P&gt;&lt;P&gt;EXPORTING&lt;/P&gt;&lt;P&gt;name = 'ICON_OKAY' "name of icon u want&lt;/P&gt;&lt;P&gt;text = 'ok' "text of the icon&lt;/P&gt;&lt;P&gt;info = 'Status' "tool -tip text&lt;/P&gt;&lt;P&gt;add_stdinf = 'X'&lt;/P&gt;&lt;P&gt;IMPORTING&lt;/P&gt;&lt;P&gt;result = status_icon&lt;/P&gt;&lt;P&gt;EXCEPTIONS&lt;/P&gt;&lt;P&gt;icon_not_found = 1&lt;/P&gt;&lt;P&gt;outputfield_too_short = 2&lt;/P&gt;&lt;P&gt;OTHERS = 3.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;when 'CANCEL'&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'ICON_CREATE'&lt;/P&gt;&lt;P&gt;EXPORTING&lt;/P&gt;&lt;P&gt;name = 'ICON_CANCEL' "name of icon u want&lt;/P&gt;&lt;P&gt;text = 'cancel' "text of the icon&lt;/P&gt;&lt;P&gt;info = 'Status' "tool -tip text&lt;/P&gt;&lt;P&gt;add_stdinf = 'X'&lt;/P&gt;&lt;P&gt;IMPORTING&lt;/P&gt;&lt;P&gt;result = status_icon&lt;/P&gt;&lt;P&gt;EXCEPTIONS&lt;/P&gt;&lt;P&gt;icon_not_found = 1&lt;/P&gt;&lt;P&gt;outputfield_too_short = 2&lt;/P&gt;&lt;P&gt;OTHERS = 3.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;endcase.&lt;/P&gt;&lt;P&gt;Similarly for others ..we can change the icon based on function code recieved &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sy-subrc = 0.&lt;/P&gt;&lt;P&gt;"success&lt;/P&gt;&lt;P&gt;sy-subrc = 1.&lt;/P&gt;&lt;P&gt;Icon does not exist&lt;/P&gt;&lt;P&gt;sy-subrc = 2.&lt;/P&gt;&lt;P&gt;Icon and text do not fit on screen&lt;/P&gt;&lt;P&gt;sy-subrc = 3.&lt;/P&gt;&lt;P&gt;Error displaying status icon&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;&amp;lt;REMOVED BY MODERATOR&amp;gt;&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Byju&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: &lt;/P&gt;&lt;P&gt;        Alvaro Tejada Galindo&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 Sep 2007 11:42:00 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-button-in-dynpro/m-p/2789952#M650777</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-13T11:42:00Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic button in Dynpro</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-button-in-dynpro/m-p/2789953#M650778</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 the screen painter go to the attributes of that push button.select the check box &amp;lt;b&amp;gt;WITH ICON&amp;lt;/b&amp;gt; and&lt;/P&gt;&lt;P&gt;in the lower tab strip(program tab)&lt;/P&gt;&lt;P&gt;select the check box &amp;lt;b&amp;gt;OUTPUT FIELD&amp;lt;/b&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;now in the pbo of the screen write like below.&lt;/P&gt;&lt;P&gt;data:&amp;lt;button name&amp;gt;(30).&lt;/P&gt;&lt;P&gt;data:but_name(30).&lt;/P&gt;&lt;P&gt;concatenate &amp;lt;icon_name&amp;gt; &amp;lt;icon text&amp;gt; into but_name sepatared by space.&lt;/P&gt;&lt;P&gt;&amp;lt;button name&amp;gt; = but_name.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;rgds,&lt;/P&gt;&lt;P&gt;bharat.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 Sep 2007 11:51:08 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-button-in-dynpro/m-p/2789953#M650778</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-13T11:51:08Z</dc:date>
    </item>
  </channel>
</rss>

