Skip to main content

Notifications

Announcements

No record found.

Finance | Project Operations, Human Resources, ...
Answered

BP warning Late bound call

(0) ShareShare
ReportReport
Posted on by 35

Hi all,

I 'm trying to use Dictionary in X++, but I got Late bound call warning

pastedimage1676518048088v1.png

Is there any way to solve this warning?

Thanks

  • Verified answer
    Martin Dráb Profile Picture
    Martin Dráb 230,466 Most Valuable Professional on at
    RE: BP warning Late bound call

    Suppressing the warning isn't rhe best solution. A better approach is actually avoiding the peformance problem.

    You should avoid CLRObject - use a concrete type instead. Unfortunately we don't know why you're trying to do it, so we can't tell you what exactly you should do instead.

    If you just want something like Dictionary and you don't .NET Interop, simply use the X++ native class for this purpose: Map.

    If you need .NET Interop but not necessarily this particular type, consider using a non-generic dictionary: HashTable.

    Or wrap the generic collection in a custom class (with a non-generic interface) and use this class in X++.

    Also, X++ has some support for generics, but it's not very good.

  • Suggested answer
    Mohit Rampal Profile Picture
    Mohit Rampal 12,550 Super User 2024 Season 1 on at
    RE: BP warning Late bound call

    Hi, You can suppress BP warning as Girish mentioned. However, there is another option as well to explore. 

    sangeethwiki.blogspot.com/.../solution-for-bp-bp-rule.html

  • Suggested answer
    GirishS Profile Picture
    GirishS 27,816 Super User 2024 Season 1 on at
    RE: BP warning Late bound call

    Hi PhucNguyen,

    You can suppress the warning.

    Refer to the below thread which is similar to the issue.

    https://community.dynamics.com/365/financeandoperations/f/dynamics-365-for-finance-and-operations-forum/399786/getting-br-warning-bpupgradecodelateboundcall-by-calling-custom-method-in-form-method-in-d365-fo

    Thanks,

    Girish S.

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

Congratulations 2024 Spotlight Honorees

Kudos to all of our 2024 community stars! 🎉

Meet the Top 10 leaders for December

Congratulations to our December super stars! 🥳

Start Your Super User Journey

Join the ranks of our community heros! 🦹

Leaderboard

#1
André Arnaud de Calavon Profile Picture

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

#2
Martin Dráb Profile Picture

Martin Dráb 230,466 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Product updates

Dynamics 365 release plans