<?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 open documents with cl_htmlviewer in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/open-documents-with-cl-htmlviewer/m-p/353750#M7148</link>
    <description>&lt;P&gt;hi, &lt;/P&gt;&lt;P&gt;i am using load_data and show_url of class cl_htmlviewer for displaying different files in new browser window. the variable lv_mimetype is set depending on the mime-type, e.g. application/pdf for pdf document or application/msword for word document.&lt;/P&gt;&lt;P&gt;with the coding below it is working perfect for PDF !!! the pdf is opened directly in new browser window.  for all other formats like word-documents, excel, etc.... i come to the "download popup"  of internet explorer. i can download the file. when i open it i get another popup which asks me with which application i want to open the file, because the type is now known.&lt;/P&gt;&lt;P&gt;so why is this not working for other formats than PDF ? why i get this popups for other documents ? i want to open the other forms just like pdf without this popups. &lt;/P&gt;&lt;P&gt;any ideas ? &lt;/P&gt;&lt;P&gt;br Martin&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;CALL METHOD cl_htmlviewer-&amp;gt;load_data
      EXPORTING
        type                 = lv_mimetype
*        size                 = i_size
      IMPORTING
        assigned_url         = gf_url
      CHANGING
        data_table           = gt_content
      EXCEPTIONS
        dp_invalid_parameter = 1
        dp_error_general     = 2
        cntl_error           = 3
        OTHERS               = 4.
 
    CALL METHOD cl_htmlviewer-&amp;gt;show_url   "data
      EXPORTING
        url                    = gf_url
        in_place               = ' '
      EXCEPTIONS
        cntl_error             = 1
        cnht_error_not_allowed = 2
        cnht_error_parameter   = 3
        dp_error_general       = 4
        OTHERS                 = 5.
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Wed, 08 Feb 2017 20:45:38 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2017-02-08T20:45:38Z</dc:date>
    <item>
      <title>open documents with cl_htmlviewer</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/open-documents-with-cl-htmlviewer/m-p/353750#M7148</link>
      <description>&lt;P&gt;hi, &lt;/P&gt;&lt;P&gt;i am using load_data and show_url of class cl_htmlviewer for displaying different files in new browser window. the variable lv_mimetype is set depending on the mime-type, e.g. application/pdf for pdf document or application/msword for word document.&lt;/P&gt;&lt;P&gt;with the coding below it is working perfect for PDF !!! the pdf is opened directly in new browser window.  for all other formats like word-documents, excel, etc.... i come to the "download popup"  of internet explorer. i can download the file. when i open it i get another popup which asks me with which application i want to open the file, because the type is now known.&lt;/P&gt;&lt;P&gt;so why is this not working for other formats than PDF ? why i get this popups for other documents ? i want to open the other forms just like pdf without this popups. &lt;/P&gt;&lt;P&gt;any ideas ? &lt;/P&gt;&lt;P&gt;br Martin&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;CALL METHOD cl_htmlviewer-&amp;gt;load_data
      EXPORTING
        type                 = lv_mimetype
*        size                 = i_size
      IMPORTING
        assigned_url         = gf_url
      CHANGING
        data_table           = gt_content
      EXCEPTIONS
        dp_invalid_parameter = 1
        dp_error_general     = 2
        cntl_error           = 3
        OTHERS               = 4.
 
    CALL METHOD cl_htmlviewer-&amp;gt;show_url   "data
      EXPORTING
        url                    = gf_url
        in_place               = ' '
      EXCEPTIONS
        cntl_error             = 1
        cnht_error_not_allowed = 2
        cnht_error_parameter   = 3
        dp_error_general       = 4
        OTHERS                 = 5.
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 08 Feb 2017 20:45:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/open-documents-with-cl-htmlviewer/m-p/353750#M7148</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2017-02-08T20:45:38Z</dc:date>
    </item>
    <item>
      <title>Re: open documents with cl_htmlviewer</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/open-documents-with-cl-htmlviewer/m-p/353751#M7149</link>
      <description>&lt;P&gt;&lt;/P&gt;&lt;P&gt;cl_htmlviewer is a little bit misleading. The class you are using is probably CL_GUI_HTML_VIEWER, and cl_htmlviewer is the variable name of the instance.&lt;/P&gt;You can never open directly a Word file in a web browser. Only PDF and image files can be directly displayed.&lt;P&gt;If you only want to start MS Word to see the document, I think you may use the Desktop Office Integration framework. The simplest way would be to use the document viewer (C_OI_CONTAINER_CONTROL_CREATOR=&amp;gt;GET_DOCUMENT_VIEWER ...)&lt;/P&gt;</description>
      <pubDate>Thu, 09 Feb 2017 20:14:21 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/open-documents-with-cl-htmlviewer/m-p/353751#M7149</guid>
      <dc:creator>Sandra_Rossi</dc:creator>
      <dc:date>2017-02-09T20:14:21Z</dc:date>
    </item>
  </channel>
</rss>

