web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Reading AOT node property

(0) ShareShare
ReportReport
Posted on by 1,312

I'm trying to populate a table by reading (AX2009) AOT node properties including MaxAccessMode. I'm having trouble getting data into a target field of dataType AccessType (from System Documention/Enums) - it inserts 0. This is the statement I'm using.

 angiListAOTSecKeys.AccessMode       = treeNode.AOTgetProperty("MaxAccessMode");

I've also tried to no avail inserting into a string field using  enum2str function.

I'm having same problem with property AOSAuthorization, otherwise all other properties are inserted into fields as desired. Any advice is appreciated.

*This post is locked for comments

I have the same question (0)
  • Verified answer
    Martin Dráb Profile Picture
    237,880 Most Valuable Professional on at

    You use the method correctly, although it's better to use a macro instead of the hard-coded text (there is #PropertyMaxAccessMode inside #Properties).

    First of all, check if 0 isn't actually the right value (it means that MaxAccessMode is None). If you get 0 instead of the right value, I would first assign the return value of AOTgetProperty() to a separate anytype variable and review what's there. Maybe you get something else than you expect and details get lost after you assign the value to a variable of a different type.

  • Mark Prouty Profile Picture
    1,312 on at

    Great troubleshooting tip!!

    I ended up creating a str field and putting the Anytype into that.

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Martin Dráb Profile Picture

Martin Dráb 4 Most Valuable Professional

#1
Priya_K Profile Picture

Priya_K 4

#3
MyDynamicsNAV Profile Picture

MyDynamicsNAV 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans