Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Small and medium business | Business Central, N...
Answered

Notification of Price Change

(1) ShareShare
ReportReport
Posted on by 378
Hi:
 
In the "Prices & Sales" FastTab of the Item Card, you can choose "Price=Cost+Profit" for the Price/Profit Calculation.
 
If you make a change to "Profit %", "Unit Price" changes automatically.
 
Also, for the Item Card, you can click the link for the "Sales Prices & Discounts" field to set up special prices and discounts.
 
Is there a way to have Business Central notify or alert the end user in some form, when he or she changes the Profit % and causes the "Unit Price" to be different from the "Sales Price" for special prices and discounts?
 
Thanks!
 
John
  • Netjacker2097 Profile Picture
    273 on at
    Notification of Price Change
    Hi,
     
    this should work for what you need if you table extend on item table. Also add some control on the user setup with the boolean for ITNotify.
     
    I have not tested this so please try in SB enviroment and ensure it all works before you add the Live.
     
        trigger OnAfterModify()
        var
            RecEmailM: Codeunit "Email Message";
            RecEmail: Codeunit Email;
            Body: Text;
            Msg: Label 'Hello <br><br>The Item No. is <strong>%1</strong>.<br><br>The Profit Percentage has changed, causing the Unit Price to be different from the Sales Price.<br><br>Regards,<br>BC System Message';
            UserSetup: Record "User Setup";
            UserIdVar: Text[100];
            EmailCreated: Boolean;
        begin
            if (Rec."Profit %" <> xRec."Profit %") and (Rec."Unit Price" <> xRec."Unit Price") then begin
                UserSetup.SETRANGE(ITNotify, TRUE);
                if UserSetup.FINDSET THEN BEGIN
                    REPEAT
                        UserIdVar := FORMAT(UserSetup."User ID");
                        Body := StrSubstNo(Msg, Rec."No.");
     
                        RecEmailM.Create(UserSetup."E-Mail", 'Item - Email Notification', Body, true);
     
                        IF NOT RecEmail.Send(RecEmailM) THEN BEGIN
                            ERROR('Failed to send email to user: %1', UserIdVar);
                        END;
                    UNTIL UserSetup.NEXT = 0;
                END;
                Message('Profit % has changed for item %1, causing the Unit Price to be different from the Sales Price.', rec."No.");
            end;
        end;
  • Verified answer
    gdrenteria Profile Picture
    15,893 Most Valuable Professional on at
  • Suggested answer
    YUN ZHU Profile Picture
    79,326 Super User 2025 Season 1 on at
    Notification of Price Change
    Hi, As far as I know there is no standard feature for this. You could look for it in My Notifications, but I think this might need customization.
     
    Hope this helps.
    Thanks.
    ZHU
     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Daivat Vartak – Community Spotlight

We are honored to recognize Daivat Vartak as our March 2025 Community…

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Kudos to the February Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 293,278 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 232,011 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156 Moderator

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans