<?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  to execute os command from ABAP program? in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-execute-os-command-from-abap-program/m-p/2742937#M637456</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can execute any operating system command as an auto-reaction to a monitoring architecture alert. The auto-reaction method CCMS_AUTO_REACT_OP_COMMAND is available to you for this purpose. For security reasons, this does, however, apply only for those commands that have previously been defined in External Operating System Commands (transaction SM69).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To use the auto-reaction method, ensure that you are using a current SAPXPG from the SAP Service Marketplace (http://service.sap.com/swdc ® Download ® Support Packages and Patches ® Entry by Application Group ® SAP NetWeaver ® SAP NETWEAVER ® SAP NETWEAVER 04 ® Entry by Component ® AS ABAP ®SAP KERNEL 6.40 32/64-BIT ® alert_%3.txt&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you are not using absolute path specifications, the file is stored in the DIR_HOME directory.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 06 Sep 2007 10:13:54 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-09-06T10:13:54Z</dc:date>
    <item>
      <title>How  to execute os command from ABAP program?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-execute-os-command-from-abap-program/m-p/2742934#M637453</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I want to execute some window commands from ABAP. What is the way to do it?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Sep 2007 09:58:03 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-execute-os-command-from-abap-program/m-p/2742934#M637453</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-06T09:58:03Z</dc:date>
    </item>
    <item>
      <title>Re: How  to execute os command from ABAP program?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-execute-os-command-from-abap-program/m-p/2742935#M637454</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi dhananjay,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. use the FM   GUI_RUN&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2. we can pass the OS command, as well as the parameters if required.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;amit m.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Sep 2007 10:01:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-execute-os-command-from-abap-program/m-p/2742935#M637454</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-06T10:01:10Z</dc:date>
    </item>
    <item>
      <title>Re: How  to execute os command from ABAP program?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-execute-os-command-from-abap-program/m-p/2742936#M637455</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;You might try out SXPG_COMMAND_EXECUTE fm as well.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Tamá&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Sep 2007 10:04:57 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-execute-os-command-from-abap-program/m-p/2742936#M637455</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-06T10:04:57Z</dc:date>
    </item>
    <item>
      <title>Re: How  to execute os command from ABAP program?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-execute-os-command-from-abap-program/m-p/2742937#M637456</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can execute any operating system command as an auto-reaction to a monitoring architecture alert. The auto-reaction method CCMS_AUTO_REACT_OP_COMMAND is available to you for this purpose. For security reasons, this does, however, apply only for those commands that have previously been defined in External Operating System Commands (transaction SM69).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To use the auto-reaction method, ensure that you are using a current SAPXPG from the SAP Service Marketplace (http://service.sap.com/swdc ® Download ® Support Packages and Patches ® Entry by Application Group ® SAP NetWeaver ® SAP NETWEAVER ® SAP NETWEAVER 04 ® Entry by Component ® AS ABAP ®SAP KERNEL 6.40 32/64-BIT ® alert_%3.txt&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you are not using absolute path specifications, the file is stored in the DIR_HOME directory.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Sep 2007 10:13:54 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-execute-os-command-from-abap-program/m-p/2742937#M637456</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-06T10:13:54Z</dc:date>
    </item>
    <item>
      <title>Re: How  to execute os command from ABAP program?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-execute-os-command-from-abap-program/m-p/2742938#M637457</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;See ht e coding below, I have used these Fm to connect to FTP server and get the Files..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*types for the ftp command result internal table&lt;/P&gt;&lt;P&gt;TYPES : BEGIN OF ty_result,&lt;/P&gt;&lt;P&gt;        text TYPE char512,&lt;/P&gt;&lt;P&gt;        END OF ty_result.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data it_result type standard table of ty_result.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*Connect to the FTP server&lt;/P&gt;&lt;P&gt;  CALL FUNCTION 'FTP_CONNECT'&lt;/P&gt;&lt;P&gt;    EXPORTING&lt;/P&gt;&lt;P&gt;      user            = lv_user           " user name pass word to connect&lt;/P&gt;&lt;P&gt;      password        = l_v_pwd&lt;/P&gt;&lt;P&gt;      host            = 'dev.eu.pm.com' " Host name here&lt;/P&gt;&lt;P&gt;      rfc_destination = 'SAPFTPA'   "destination name&lt;/P&gt;&lt;P&gt;*Ask your functional people for the above data&lt;/P&gt;&lt;P&gt;    IMPORTING&lt;/P&gt;&lt;P&gt;      handle          = v_handle&lt;/P&gt;&lt;P&gt;    EXCEPTIONS&lt;/P&gt;&lt;P&gt;      not_connected   = 1&lt;/P&gt;&lt;P&gt;      OTHERS          = 2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  IF sy-subrc &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*Changing directory&lt;/P&gt;&lt;P&gt;  CONCATENATE 'cd' '&amp;lt;file path&amp;gt;' INTO l_v_cmd SEPARATED BY space.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;you can also ser 'DIR in l_v_cmd which opens the directory and all the folders *get into it_result table..&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*Execute the FTP Command&lt;/P&gt;&lt;P&gt;  CALL FUNCTION 'FTP_COMMAND'&lt;/P&gt;&lt;P&gt;    EXPORTING&lt;/P&gt;&lt;P&gt;      handle        = v_handle&lt;/P&gt;&lt;P&gt;      command       = l_v_cmd &lt;/P&gt;&lt;P&gt;    TABLES&lt;/P&gt;&lt;P&gt;      data          = it_result&lt;/P&gt;&lt;P&gt;    EXCEPTIONS&lt;/P&gt;&lt;P&gt;      tcpip_error   = 1&lt;/P&gt;&lt;P&gt;      command_error = 2&lt;/P&gt;&lt;P&gt;      data_error    = 3&lt;/P&gt;&lt;P&gt;      OTHERS        = 4.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  IF sy-subrc &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;rewards if useful,&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;nazeer&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Sep 2007 10:30:42 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-execute-os-command-from-abap-program/m-p/2742938#M637457</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-06T10:30:42Z</dc:date>
    </item>
  </channel>
</rss>

