48

We have apps that runs a lot of different logic from Base Application and other apps in the background, as scheduled tasks or via Web Services (API and/or OData). One scenario that we cannot handle today is when the File.DownloadFromStream() function is invoked, which results in an unhandled “Callback functions are not allowed” error.


We would like to suggest a new platform event to handle this scenario:


OnDownloadFromStream(FileStream: InStream; DialogTitle: Text; ToFolder: Text; ToFilter: Text; ToFile: Text; var Success: Boolean)

Or

OnDownloadFromStream(FileStream: InStream; ObjectPayload: JsonObject; var Success: Boolean)

 

This event should then be exposed for extensions in codeunit 419 "File Management".


If a subscriber sets the Success parameter to true, the download should be suppressed and no “Callback functions are not allowed” error thrown if running in a background session.


This would make it possible to create extensions that handles all kinds of export of data from Business Central.

Category: Development
STATUS DETAILS
New

Comments

J

Great!

Category: Development