Quantcast
Channel: SCN : All Content - All Communities
Viewing all articles
Browse latest Browse all 2169

Sapui5 - Xml view open pdf

$
0
0

Hi, I'm developing a Fiori custom web application and I need to open a pdf file in a xml view.

 

I've develop a custom oData service for implementing the method

 

/IWBEP/IF_MGW_APPL_SRV_RUNTIME~GET_STREAM

Returning the data stream as:

 

ls_stream-value = l_value.
ls_stream-mime_type = 'application/pdf'.
copy_data_to_ref( EXPORTING is_data = ls_stream                              CHANGING  cr_data = er_stream )

In xml view I've put

 

<core:HTML id="idFrame"/>

The relative controller is

 

var html = this.getView().byId("idFrame");
var url = "/sap/opu/odata/sap/*****('YYYYY')/$value";
html.setContent('<iframe src="' + url +'" width="100%" height="100%"></iframe>');

When I open the view nothing appears and in Chrome console I've got this message

Capture.PNG

How can I solve it out?

 

Kind regards,

Giacomo


Viewing all articles
Browse latest Browse all 2169

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>