Code annotations in AL – Please, don’t!

  • Post comments:16 Comments

One of good practices of writing C/AL Code for Microsoft Dynamics NAV since the dawn of civilization was annotating (commenting) code changes. If you are not sure what I mean by that, this is what I am talking about:

While standards varied about > vs +, or < vs -, or what the annotations should include, there was absolute consensus that annotating changes is an absolute must.

And it was a must. It was such an important rule that everyone followed it without questions asked. In my career, I’ve seen one or two situations of somebody changing or deleting a line of code without leaving any comment, and I’ve seen quite a lot of code, believe you me. It was that important.

It was that important in fact that it was one of the first things developers learned when they signed up for the job, and it was one of the rules they all followed from their first day.

(more…)

Continue Reading Code annotations in AL – Please, don’t!
Module Binder Pattern proposal
Zlata Praha, by Roman Boed

Module Binder Pattern proposal

  • Post comments:7 Comments

Whoa! This has been quite an event, the Directions EMEA 2016 in Prague. There has never been this many people (1.700+) and it was quite a pleasure connecting again with old friends, and meeting new friends. Also, it has been quite a pleasure listening to many good sessions, and an even bigger pleasure delivering four of them.

And this is why I am blogging now – to follow up on my promise during my Polymorphic Event Patterns for C/AL. I promised you that I’d post my pattern proposal online, and here I am doing it.

Let’s get started.

(more…)

Continue Reading Module Binder Pattern proposal

OnAfter table event subscriber patterns and antipatterns

  • Post comments:17 Comments

The purpose of events is to simplify business logic customization while not impeding upgradeability and general extensibility. However, there is one particular class of events that may cause troubles: OnAfter* table events. There are four of them: OnAfterInsert, OnAfterModify, OnAfterDelete, and OnAfterRename.

If you need them, you must be careful.

(more…)

Continue Reading OnAfter table event subscriber patterns and antipatterns

Development best practices – the aftermath

  • Post comments:2 Comments

image So I would guess that was it. I’m just returning to Kristiansand, my Norwegian base, after delivering the “Microsoft Dynamics NAV 2009 Development Best Practices” course to a partner, my first custom-developed training ever. My impression is—mission accomplished.

I was not sure at first how this would turn out. Teaching NAV best practices to people some of whom have more experience than I’ll have any time soon, isn’t an easy thing. The challenge for me was—how to deliver something new, really valuable to those people, something they could go home with saying “wow, if only I knew this earlier”.

(more…)

Continue Reading Development best practices – the aftermath