<?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: Transfer internal table data into MSword in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536842#M1072000</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;use OLE in abap. In Tcode DWDM you find some example.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards, Dieter&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 24 Sep 2008 11:41:10 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-09-24T11:41:10Z</dc:date>
    <item>
      <title>Transfer internal table data into MSword</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536832#M1071990</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Gurus,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I want to display the data that i fetched to internal table in msword.means i want to see the output in msword.please provide me the sample code.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Sep 2008 10:42:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536832#M1071990</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-09-24T10:42:14Z</dc:date>
    </item>
    <item>
      <title>Re: Transfer internal table data into MSword</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536833#M1071991</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;  Use GUI_DOWNLOAD function module. give filename as &lt;/P&gt;&lt;P&gt;&amp;lt;filename&amp;gt;.doc&lt;/P&gt;&lt;P&gt;   &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
   CALL FUNCTION 'GUI_DOWNLOAD'
    EXPORTING
      filename                = 'D:\flight.doc'  "&amp;lt;----extension for Msword file
      filetype                      = 'ASC'
   &lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Abhijeet&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Sep 2008 10:48:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536833#M1071991</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-09-24T10:48:10Z</dc:date>
    </item>
    <item>
      <title>Re: Transfer internal table data into MSword</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536834#M1071992</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Abhi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;transfer the data means i want to see the data in msword when i press execute button.i think i have to use OLE.but i dont have much knowledge on that.if you know how to please tell me.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Sep 2008 10:52:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536834#M1071992</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-09-24T10:52:45Z</dc:date>
    </item>
    <item>
      <title>Re: Transfer internal table data into MSword</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536835#M1071993</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hii&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;we can download data in to .txt or .xls and .doc using gui_download FM.also try using&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;POPUP_AND_DOWNLOAD_FOR_WORD&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;CALL FUNCTION 'GUI_DOWNLOAD'
    EXPORTING
*   BIN_FILESIZE                  =
 filename   = 'C:\Documents and Settings\Desktop\twi1.doc'
     filetype                      = 'ASC'
*   APPEND                        = ' '
*     write_field_separator         = 'X'
*   HEADER                        = '00'
*   TRUNC_TRAILING_BLANKS         = ' '&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;twinkal&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Sep 2008 10:53:25 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536835#M1071993</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-09-24T10:53:25Z</dc:date>
    </item>
    <item>
      <title>Re: Transfer internal table data into MSword</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536836#M1071994</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 this sample code, by this code data of internal table will be downloaded in MSWORD file with name Flight.&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
REPORT  z_FILE_DOWNLOAD.
DATA: w_name(90) TYPE c.
DATA:
  BEGIN OF fs_flight,
    carrid   LIKE sflight-carrid,
    connid   LIKE sflight-connid,
    fldate   LIKE sflight-fldate,
    price    LIKE sflight-price,
    currency LIKE sflight-currency,
  END OF fs_flight.

DATA:
  t_flight LIKE
     TABLE OF
           fs_flight.


SELECT-OPTIONS:
  s_carrid FOR fs_flight-carrid.


START-OF-SELECTION.
  SELECT carrid
         connid
         fldate
         price
         currency
    FROM sflight
    INTO TABLE t_flight
   WHERE carrid IN s_carrid.


CALL FUNCTION 'GUI_DOWNLOAD'
  EXPORTING

filename =            'D:\flight.doc'

   FILETYPE                      = 'ASC'

   WRITE_FIELD_SEPARATOR         = 'X'

  tables
    data_tab                      = t_flight
 EXCEPTIONS
   FILE_WRITE_ERROR              = 1
   NO_BATCH                      = 2
   GUI_REFUSE_FILETRANSFER       = 3
   INVALID_TYPE                  = 4
   NO_AUTHORITY                  = 5
   UNKNOWN_ERROR                 = 6
   HEADER_NOT_ALLOWED            = 7
   SEPARATOR_NOT_ALLOWED         = 8
   FILESIZE_NOT_ALLOWED          = 9
   HEADER_TOO_LONG               = 10
   DP_ERROR_CREATE               = 11
   DP_ERROR_SEND                 = 12
   DP_ERROR_WRITE                = 13
   UNKNOWN_DP_ERROR              = 14
   ACCESS_DENIED                 = 15
   DP_OUT_OF_MEMORY              = 16
   DISK_FULL                     = 17
   DP_TIMEOUT                    = 18
   FILE_NOT_FOUND                = 19
   DATAPROVIDER_EXCEPTION        = 20
   CONTROL_FLUSH_ERROR           = 21
   OTHERS                        = 22
          .
IF sy-subrc EQ 0.
  MESSAGE 'Download successful' TYPE 'S'.
ELSE.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
*         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Abhijeet&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Sep 2008 10:55:02 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536836#M1071994</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-09-24T10:55:02Z</dc:date>
    </item>
    <item>
      <title>Re: Transfer internal table data into MSword</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536837#M1071995</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;HELLO&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;YOU WANT TO DOWNLOAD WORD FILE USE FM - GUI_DOWNLOAD IN FILE NAME PARAMETER WHERE YOU GIVE PATH THERE U GIVE (.DOC AT LAST).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;HOPE THIS WILL HELP YOU.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Sep 2008 11:09:50 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536837#M1071995</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-09-24T11:09:50Z</dc:date>
    </item>
    <item>
      <title>Re: Transfer internal table data into MSword</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536838#M1071996</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Use the code below to download and show in word.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;CALL FUNCTION 'GUI_DOWNLOAD'
  EXPORTING
filename =            'c:\file.doc'
FILETYPE                      = 'ASC'
WRITE_FIELD_SEPARATOR         = 'X'
tables
    data_tab                      = itab_data.

IF sy-subrc eq 0.
CALL FUNCTION 'GUI_RUN'
  EXPORTING
    command          = 'WINWORD'
   PARAMETER        = 'c:\file.doc'.
ENDIF.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Karthik D&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Sep 2008 11:10:04 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536838#M1071996</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-09-24T11:10:04Z</dc:date>
    </item>
    <item>
      <title>Re: Transfer internal table data into MSword</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536839#M1071997</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Karthik,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is help me.But it is creating a file in clients system.i want to display the output in msword without saving the data.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thnaks for your response.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Sep 2008 11:18:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536839#M1071997</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-09-24T11:18:52Z</dc:date>
    </item>
    <item>
      <title>Re: Transfer internal table data into MSword</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536840#M1071998</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If you dont want the file just give the file path to temp folder.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But i think what you need cannot be done without storing the file in the system.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Karthik D&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Sep 2008 11:23:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536840#M1071998</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-09-24T11:23:38Z</dc:date>
    </item>
    <item>
      <title>Re: Transfer internal table data into MSword</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536841#M1071999</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Karthik,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If i use the path like "D:\file" it will work if we have d drive.otherwise it will not .we are not sure that the client will have the same drives.please check it once.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Sep 2008 11:24:09 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536841#M1071999</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-09-24T11:24:09Z</dc:date>
    </item>
    <item>
      <title>Re: Transfer internal table data into MSword</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536842#M1072000</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;use OLE in abap. In Tcode DWDM you find some example.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards, Dieter&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Sep 2008 11:41:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536842#M1072000</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-09-24T11:41:10Z</dc:date>
    </item>
    <item>
      <title>Re: Transfer internal table data into MSword</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536843#M1072001</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;Use the following FM to get file name&amp;amp; path from the user before the above said function modules and assign the lv_filename to GUI_DOWNLOAD and GUI_RUN Fms.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
data : lv_filename TYPE string, 
         lv_path TYPE string,     
         lv_fullpath TYPE string.

CALL METHOD cl_gui_frontend_services=&amp;gt;file_save_dialog
      EXPORTING
        window_title         = 'Save as'
        default_extension    = 'doc'
        default_file_name    = 'file.doc'
        file_filter          = '*.doc'
        prompt_on_overwrite  = 'X'
      CHANGING
        filename             = lv_filename
        path                 = lv_path
        fullpath             = lv_fullpath
      EXCEPTIONS
        cntl_error           = 1
        error_no_gui         = 2
        not_supported_by_gui = 3
        OTHERS               = 4.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This will show the file save dialog box and get the path from the user.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Karthik D&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Sep 2008 11:41:46 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/transfer-internal-table-data-into-msword/m-p/4536843#M1072001</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-09-24T11:41:46Z</dc:date>
    </item>
  </channel>
</rss>

