<?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: Write File to Server in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/write-file-to-server/m-p/2218129#M475830</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Tamilarasan,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I tried using the ip, but I get the message "Invalid Argument".  I pinged the IP via t-code SM49 and got a response, so I don't know what the invalid argument is.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 24 Apr 2007 15:43:57 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-04-24T15:43:57Z</dc:date>
    <item>
      <title>Write File to Server</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/write-file-to-server/m-p/2218127#M475828</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;I'm trying to write a file to a server.  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When I specify the path as a drive on the application server('E:\usr\sap\trans\ftp\QUERIES\test.TXT'), it writes the file ok.  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When I specify another server(&lt;BR /&gt;testserver\share\test.txt), it doe not write.  The message i get is "No such file or directory"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The basis guys mapped a drive on the application server to the drive letter S(with a domain username and password) to the other server.  I then tried "S:\test.txt" but still it does not write.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Does anybody have an idea of why I can't write to the other server, or how I can write to the other server?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm on a 4.7 system and here is the code i'm using:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
DATA:
*   lv_file(255)   TYPE c VALUE 'E:usrsaptransftpQUERIEStest.txt',  "works
*   lv_file(255)   TYPE c VALUE '\testserversharetest.txt'  "does not work
      lv_file(255)   TYPE c VALUE 'S:test.txt',                     "does not work
      lv_line        TYPE string,
      lv_msg(60) TYPE c.


** open the file
OPEN DATASET lv_file  IN TEXT MODE ENCODING DEFAULT FOR OUTPUT MESSAGE lv_msg.

IF sy-subrc &amp;lt;&amp;gt; 0.
  MESSAGE e000(zz) WITH lv_msg.
ENDIF.

lv_line = 'This is a test'.

TRANSFER lv_line TO lv_file.

** close file
CLOSE DATASET lv_file .
IF sy-subrc &amp;lt;&amp;gt; 0.
  MESSAGE i000(zz) WITH 'Error closing file ' lv_file .
ENDIF.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 24 Apr 2007 14:51:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/write-file-to-server/m-p/2218127#M475828</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-24T14:51:34Z</dc:date>
    </item>
    <item>
      <title>Re: Write File to Server</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/write-file-to-server/m-p/2218128#M475829</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi&lt;/P&gt;&lt;P&gt;  u specify that these (&lt;BR /&gt;testserver\share\test.txt) is not working bcz we cannot give the server name just like that u specify the ip address of the application server for which u want to write the file.e.g(&lt;BR /&gt;100.100.2.10\share\..) .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;try this one it would be helpful.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 24 Apr 2007 15:10:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/write-file-to-server/m-p/2218128#M475829</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-24T15:10:20Z</dc:date>
    </item>
    <item>
      <title>Re: Write File to Server</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/write-file-to-server/m-p/2218129#M475830</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Tamilarasan,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I tried using the ip, but I get the message "Invalid Argument".  I pinged the IP via t-code SM49 and got a response, so I don't know what the invalid argument is.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 24 Apr 2007 15:43:57 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/write-file-to-server/m-p/2218129#M475830</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-24T15:43:57Z</dc:date>
    </item>
  </channel>
</rss>

