Hi, Readers.
The public preview for Dynamics 365 Business Central 2026 release wave 2 (BC29) is available. Learn more: Link.
I will continue to test and share some new features that I hope will be helpful. In this post, I would like to talk about Added the IsDirty property to the Record API.
Added the IsDirty property to the Record API:
Added the
https://marketplace.visualstudio.com/items/ms-dynamics-smb.al/changelogIsDirtyproperty to the Record API.

Use the Record API IsDirty property to determine whether a record instance contains unsaved changes before deciding to validate, save, or otherwise process it.

procedure IsDirty(): Boolean
Gets a boolean value that indicates whether the current in-memory record instance has different values than when it was loaded from the database.

Below is a simple example. I modified the name of customer 10000 but have not committed the changes to the database yet. At this point, if you use IsDirty to perform the check, it will throw an error. Because the current in-memory record instance has different values than when it was loaded from the database.


So this allows developers to determine whether a record has been modified since it was retrieved or last persisted.
PS:
‘IsDirty’ is not available in runtime version ‘17.0’. The supported runtime versions are: ‘18.0’ or greater. AL AL0666

Great. Give it a try!!!😁
END
Hope this will help.
Thanks for reading.
ZHU




コメント