17

Currently there is no possibility to handle a background task on a page which is based on on table with scope onprem (i.e. Extension Management)


many other things can be done through eventsubscribers in a codeunit. we can even enqueue a page background task in the OnOpenPageEvent but can not respond on Task completion or error.




To fix this i recommend to introduce new generic events:


[EventSubscriber(ObjectType::Page, Page::"Extension Management", OnPageBackgroundTaskCompletedEvent, '', false, false)]

local procedure OnPageBackgroundTaskError(TaskId: Integer; ErrorCode: Text; ErrorText: Text; ErrorCallStack: Text; var IsHandled: Boolean)


[EventSubscriber(ObjectType::Page, Page::"Extension Management", OnPageBackgroundTaskErrorEvent, '', false, false)]

local procedure trigger OnPageBackgroundTaskCompleted(TaskId: Integer; Results: Dictionary of [Text, Text])

Category: Development
STATUS DETAILS
Needs Votes
Ideas Administrator

Thank you for this suggestion! Currently this is not on our roadmap. We are tracking this idea and if it gathers more votes and comments we will consider it in the future. Best regards, Business Central Team