Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics AX forum
Answered

Business connector call non-static class method - Dynamics 09

Posted on by 2,470

Hi

1) I have an X++ class with a non-static method.

2) I want to call this non-static method from BC.Net within a WCF service

In the past I would of used "CallStaticClassMethod" to call a static method - but this approach will not work this time!

I believe I have to create an instance of the class (will this be in the WCF service method using BC.Net)?

  • Verified answer
    Bilal Issa Profile Picture
    Bilal Issa 4,370 on at
    RE: Business connector call non-static class method - Dynamics 09

    Hi,

    Yes, you will need to create an  instance of the class first like the following.

    AxaptaObject class;

    ;

    class= ax.CreateAxaptaObject(ClassName);

    class.Call(methodName, paremeters)

    Regards,

    Bilal

Helpful resources

Quick Links

Dynamics 365 Community Update – Sep 16th

Welcome to the next edition of the Community Platform Update. This is a weekly…

Announcing Our 2024 Season 2 Super Users!

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

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 290,353 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 228,251 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,148

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans