BC Friday Tips #9 When dealing with breaking changes, paying attention to the signature is important

Here’s a quick #BCTips for the #msdyn365bc developers out there!

When dealing with breaking changes, paying attention to the signature is important.

Let’s take the new BC Foundation No. Series as an example.

New No Series

Previously, we had:

codeunit 396 NoSeriesManagement
procedure GetNextNo(NoSeriesCode: Code[20]; SeriesDate: Date; ModifySeries: Boolean) Result: Code[20]


Now, we have:

codeunit 310 "No. Series"
procedure GetNextNo(NoSeriesCode: Code[20]; UsageDate: Date; HideErrorsAndWarnings: Boolean): Code[20]


Although the procedure name and parameter type remain the same, causing no error, the behaviour differs due to the last parameter: ModifySeries in the old version versus HideErrorsAndWarnings in the new one.

Make sure to thoroughly read the signature and use test automation to catch this kind of error.

thatnavguy

Experienced NZ-based NAV Developer and Consultant with 15+ years of experience leading multiple IT projects, performing business analyst, developing, implementing, and upgrading Dynamics NAV and Business Central. Passionate to deliver solution that focuses on user-friendly interface while keeping high standard of compliance with the needs.

You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *