In this video, I look at how to change Business Central posting behaviour by subscribing to an event and write a single line of code.
Tag Archives: Event
Cross Session Events and SELECTLATESTVERSION
Recently I worked on something very interesting related to a integration between MS Dynamics Nav and an external payment service provider. I had to use custom Cross Session Events to solve a problem which I think it’s worth sharing. So this why this post.
How to publish your own Event in Business Central using AL Code?
Publishing your own event means in a scenario where you are not able to find standard events , you can also define your event and publish it for use.
For Example:
In Job Journal Line page you have no event in posting date field.
EventSubscribers
EventSubscribers are a nice feature to add code to triggers in standard objects. It’s the replacement for changing the code directly in standard objects.
Look up events and insert event subscriber in code, use the new Shift+Alt+E shortcut in the AL code editor to invoke a list of all events
A core part of extension-based “customization” is the use of events and event subscribers.
To identify an event and generate an event subscriber code template, we added the Event Recorder in the client some time ago, allowing recording and inspecting of thrown events; however, in many cases, developers are either aware of the event they want to subscribe to or want to have a fast way to search for the event (with type ahead/completion) and then insert event subscriber in code context.
Feature details
Use the new Shift+Alt+E shortcut in the AL code editor to invoke a list of all events.
Look up events and insert event subscriber in code, use the new Shift+Alt+E shortcut in the AL code editor to invoke a list of all events.
A core part of extension-based “customization” is the use of events and event subscribers.
To identify an event and generate an event subscriber code template, we added the Event Recorder in the client some time ago, allowing recording and inspecting of thrown events; however, in many cases, developers are either aware of the event they want to subscribe to or want to have a fast way to search for the event (with type ahead/completion) and then insert event subscriber in code context.
Feature details
Use the new Shift+Alt+E shortcut in the AL code editor to invoke a list of all events.
Dynamics 365 Business Central: obsoleting events
I’ve written a lot in the past about handling breaking schema changes on extensions and the best practice to use the ObsoleteState object property to signal to your developers or third-party ISV users of your extensions that you’re planning to remove something in your codebase.