Skip to content

[Event Change Request] Codeunit 5611 "Calculate Normal Depreciation" - OnBeforeSetHalfYearConventionMethod() #30409

Description

Why do you need this change?

It's related to the issue #28082. Although the integration event allows us to apply our own logic when calculating depreciation with Use Half-Year Convention, the NewYearDate parameter is currently passed by value. As a result, any modifications made by the subscriber are not reflected in the subsequent depreciation calculation, and Business Central continues to use its original NewYearDate value. Passing NewYearDate by reference would enable extensions to override the calculated date as intended and ensure the depreciation calculation uses the updated value.

Describe the request

Please update the NewYearDate parameter to be passed by reference.
Example:

[IntegrationEvent(false, false)]
    local procedure OnBeforeSetHalfYearConventionMethod(FADeprBook: Record "FA Depreciation Book"; DeprMethod: Enum "FA Depr. Method Internal"; Year365Days: Boolean; FirstDeprDate: Date; var NewYearDate: Date; var Result: Boolean; var IsHandled: Boolean)
    begin
    end;

Internal work item: AB#646465

Metadata

Metadata

Assignees

No one assigned

    Labels

    FinanceGitHub request for Finance areaevent-requestRequest for adding an event

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions