Skip to main content

Notifications

Announcements

No record found.

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

May I know what is the use of OnAssistEdit trigger.

(0) ShareShare
ReportReport
Posted on by 186

I am unable to find what is the use of page field trigger i.e: OnAssistEdit. if any one knows well about it. please share the knowledge.

  • Suggested answer
    JAngle Profile Picture
    JAngle 33,159 on at
    RE: May I know what is the use of OnAssistEdit trigger.

    Example from the base app from the contact card page below. It largely depends on what UX you want. Lookups have a dropdown menu displayed. Whereas an assist edit opens a pre filtered chosen page:

    field(Name; Name)
    {
    ApplicationArea = All;
    AssistEdit = true;
    Importance = Promoted;
    ShowMandatory = true;
    ToolTip = 'Specifies the name of the contact. If the contact is a person, you can click the field to see the Name Details window.';

    trigger OnAssistEdit()
    var
    Contact: Record Contact;
    begin
    if "No." = '' then begin
    Insert(true);
    Commit;
    end;
    Contact := Rec;
    Contact.SetRecFilter;
    if Contact.Type = Contact.Type::Person then begin
    Clear(NameDetails);
    NameDetails.SetTableView(Contact);
    NameDetails.SetRecord(Contact);
    NameDetails.RunModal;
    end else begin
    Clear(CompanyDetails);
    CompanyDetails.SetTableView(Contact);
    CompanyDetails.SetRecord(Contact);
    CompanyDetails.RunModal;
    end;
    Rec := Contact;
    CurrPage.Update(false);
    end;
    }

  • Verified answer
    tanya07 Profile Picture
    tanya07 1,554 on at
    RE: May I know what is the use of OnAssistEdit trigger.

    Hi,

    please follow the logic for field No. in the Job Card, as below :

    pastedimage1651490145428v1.png

    Thanks,

    Tanya Kharbanda

    Don't forget to help the community by verifying the answer if your question has been answered. It will let others know that the topic has a verified answer.

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 Verified Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

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

#2
Martin Dráb Profile Picture

Martin Dráb 230,445 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans