Skip to Content

Consume oDataService to create a document

Dear Experts

I followed the Blog 'File Upload/Download through NetWeaver Gateway' .

Now I would like to consume this oDataService from a SAPUI5 Application. The View Type of the Application is XML and I am using the sap.m.UploadCollection.

On the Gateway I have the following Request-URI:

/sap/opu/odata/sap/<MY-FUNCTION>/FileSet('Test-jpg.jpg')/$value

Where in the Controller.js file do I have to call the oDataService?
And how do I call the oDataService?

Thanks for the kind support.

Best regards
Christophe

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • May 30, 2017 at 03:47 PM

    Check the link for uploading the files. https://sapui5.hana.ondemand.com/explored.html#/sample/sap.m.sample.UploadCollection/code

    The oData service can be used when the user clicks on the upload button/event accompanying the control.

    Regards,

    Sharath

    Add comment
    10|10000 characters needed characters exceeded

    • Hi Christoph,

      Have you managed to made UploadCollection UI element working.

      After going through many blogs I noticed that CREATE_STREAM method of DPC_EXT class is called when we try to upload document using this UI element.

      But in my case CREATE_STREAM method is not triggering.

      Do you have working code for this UI element. It will be really helpful if you can share the same so that I can understand how this UI element works.

      Regards,

      Harish