Skip to main content

Notifications

Announcements

No record found.

Small and medium business | Business Central, N...
Answered

Need to do Blank Shipment date on sales Order.

Posted on by 1,654

Hi All,

I want to Shipment date should not be automatically filled when creating a new sales order. currently It is filled Automatically, and it is today date. I have tried the below code but that is not work for me. Can anyone give me a solution? What was the problem?

pastedimage1678529522050v1.png

//Code

tableextension 50101 INK_SalesOrder extends "Sales Header"
{
    trigger OnInsert()
    begin
        if "Sell-to Customer Name" <> '' then begin
            "Shipment Date" := 0D;
            Modify();
        end;
    end;
}
Thank You.
  • Inkey Solutions Profile Picture
    Inkey Solutions 1,654 on at
    RE: Need to do Blank Shipment date on sales Order.

    Thank you so much, it is work.

  • Verified answer
    DAnny3211 Profile Picture
    DAnny3211 9,272 Super User 2024 Season 1 on at
    RE: Need to do Blank Shipment date on sales Order.

    hello

    subscribe to this event:

    OnInitRecordOnBeforeAssignmentShipmentDate(Rec, IsHandled);

    like this:

    [EventSubscriber(ObjectType::Table, 36, 'OnInitRecordOnBeforeAssignShipmentDate', '', false, false)]

    local procedure MyProcedure(var SalesHeader: Record "Sales Header";var IsHandled: Boolean)

    begin

       IsHandled:=true;

    end;

    check my answer if it was helpful, thanks

    DAniele

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,269 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,198 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans