<?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 Call Java from ABAP in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-call-java-from-abap/m-p/8095637#M1615889</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Anybody can help on this requirement.  Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 04 Aug 2011 10:05:49 GMT</pubDate>
    <dc:creator>former_member190312</dc:creator>
    <dc:date>2011-08-04T10:05:49Z</dc:date>
    <item>
      <title>How to Call Java from ABAP</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-call-java-from-abap/m-p/8095635#M1615887</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have installed JCO &amp;amp; created the RFC in SAP. i have used below code to test my RFC connection &amp;amp; it's working fine.&lt;/P&gt;&lt;P&gt;But In the below report, where to call the JAVA Program &amp;amp; what code i should use to call java code . &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Actually my ABAP requirement is to download a file. Then i need to call JAVA program, inside ABAP, to encrypt the downloaded file. Here, Java program is used to encrypt the file. Now question is, how to call the Java program inside the ABAP code.  Please advice with the code sample. Thanks a lot.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REPORT  z_jco_test.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PARAMETERS: requtext LIKE sy-lisel.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: echotext LIKE sy-lisel,&lt;/P&gt;&lt;P&gt;      resptext LIKE sy-lisel,&lt;/P&gt;&lt;P&gt;      rfctest TYPE TABLE OF rfctest,&lt;/P&gt;&lt;P&gt;      wa_rfctest TYPE rfctest.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;wa_rfctest-rfcdata1 = requtext.&lt;/P&gt;&lt;P&gt;wa_rfctest-rfcdata2 = 'Hello World'.&lt;/P&gt;&lt;P&gt;APPEND wa_rfctest TO rfctest.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'RFC_PING'&lt;/P&gt;&lt;P&gt;  DESTINATION 'JCO'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'STFC_CONNECTION'&lt;/P&gt;&lt;P&gt;  DESTINATION 'JCO'&lt;/P&gt;&lt;P&gt;  EXPORTING&lt;/P&gt;&lt;P&gt;    requtext = requtext&lt;/P&gt;&lt;P&gt;  IMPORTING&lt;/P&gt;&lt;P&gt;    echotext = echotext&lt;/P&gt;&lt;P&gt;    resptext = resptext&lt;/P&gt;&lt;P&gt;  TABLES&lt;/P&gt;&lt;P&gt;    rfctest  = rfctest.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;WRITE: 'Echo Text: ', echotext.&lt;/P&gt;&lt;P&gt;WRITE: 'Response Text: ', resptext.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOOP AT rfctest INTO wa_rfctest.&lt;/P&gt;&lt;P&gt;  WRITE: / 'rfcdata1: ', wa_rfctest-rfcdata1.&lt;/P&gt;&lt;P&gt;  WRITE: / 'rfcdata2: ', wa_rfctest-rfcdata2.&lt;/P&gt;&lt;P&gt;ENDLOOP.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Aug 2011 15:17:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-call-java-from-abap/m-p/8095635#M1615887</guid>
      <dc:creator>former_member190312</dc:creator>
      <dc:date>2011-08-03T15:17:55Z</dc:date>
    </item>
    <item>
      <title>Re: How to Call Java from ABAP</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-call-java-from-abap/m-p/8095636#M1615888</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Anybody can help on this requirement. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;pabi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Aug 2011 06:25:28 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-call-java-from-abap/m-p/8095636#M1615888</guid>
      <dc:creator>former_member190312</dc:creator>
      <dc:date>2011-08-04T06:25:28Z</dc:date>
    </item>
    <item>
      <title>Re: How to Call Java from ABAP</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-call-java-from-abap/m-p/8095637#M1615889</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Anybody can help on this requirement.  Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Aug 2011 10:05:49 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-call-java-from-abap/m-p/8095637#M1615889</guid>
      <dc:creator>former_member190312</dc:creator>
      <dc:date>2011-08-04T10:05:49Z</dc:date>
    </item>
    <item>
      <title>Re: How to Call Java from ABAP</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-call-java-from-abap/m-p/8095638#M1615890</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi pabitra,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;perhaps a bit more complex. You will have to distribute a HTTP Request Using the SAP Web Dispatcher. Check here for more details: [SAP Web Application Server with ABAP and J2EE|http://help.sap.com/saphelp_47x200/helpdata/EN/53/97583c2439e66fe10000000a114084/frameset.htm]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Didn't you ask yesterday? ([Calling Java program from ABAP|&lt;A class="jive_macro jive_macro_message" href="https://community.sap.com/" __jive_macro_name="message" modifiedtitle="true" __default_attr="10509951"&gt;&lt;/A&gt;]).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Clemens&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Aug 2011 13:12:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-call-java-from-abap/m-p/8095638#M1615890</guid>
      <dc:creator>Clemenss</dc:creator>
      <dc:date>2011-08-04T13:12:59Z</dc:date>
    </item>
    <item>
      <title>Re: How to Call Java from ABAP</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-call-java-from-abap/m-p/8095639#M1615891</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;You might accomplish your goal using external operating system commands.&lt;/P&gt;&lt;P&gt;1) Define in SM69 an external command, letu2019s say ZJAVA. This command will execute a script on the operating system, letu2019s call it calljava.sh.&lt;/P&gt;&lt;P&gt;2) In script calljava.sh you just call java, passing some parameters. For example, java $1 $2 $3 $4 $5 $6 $7&lt;/P&gt;&lt;P&gt;3) In your ABAP program you call the ZJAVA external command and pass parameters to it. Of course, one of the parameters must be your Java program name.&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
  CALL FUNCTION 'SXPG_COMMAND_EXECUTE'
    EXPORTING
      commandname                   = l_command
      additional_parameters         = l_param
      trace                         = 'X'
    IMPORTING
      status                        = l_status
      exitcode                      = l_exitcode
    TABLES
      exec_protocol                 = l_exec_protocol_itab
    EXCEPTIONS
      no_permission                 = 1u2026
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Aug 2011 19:08:05 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-call-java-from-abap/m-p/8095639#M1615891</guid>
      <dc:creator>gabriel_pill-kahan</dc:creator>
      <dc:date>2011-08-04T19:08:05Z</dc:date>
    </item>
    <item>
      <title>Re: How to Call Java from ABAP</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-call-java-from-abap/m-p/8095640#M1615892</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi  Clemens,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your information. what are the things i should install so that i can use SSF function modules in ABAP to encrypt the file. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thnak a lot.&lt;/P&gt;&lt;P&gt;  pabi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 06 Aug 2011 05:09:43 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-call-java-from-abap/m-p/8095640#M1615892</guid>
      <dc:creator>former_member190312</dc:creator>
      <dc:date>2011-08-06T05:09:43Z</dc:date>
    </item>
  </channel>
</rss>

