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)

How to Assign Button/field property only for one or two users

(0) ShareShare
ReportReport
Posted on by 1,260

Hi all,

I have a button created on a form and I want the button only to be visible for userid "pjackson". How can I do this?

*This post is locked for comments

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

    Configure security accordingly. For example, create a new role with access to the button (don't grant it to other roles) and assign this role only to the single user.

  • André Arnaud de Calavon Profile Picture
    301,088 Super User 2025 Season 2 on at

    Hi D_Meethu,

    Can you tell if this button is a common Button control or a Menu-item button? Martin is correct about the security role. But the implementation for these type of controls are different

    - A menu item button can be managed by creating a privilege and add the menu item with the required access level.

    - For a button, you need to set the NeededPermission property to Manual and set Autodeclaration to yes. Then you can create a privilege or role where you can add the button under the permissions node of the securable object.

  • Daljit Kaur Rahsi Profile Picture
    1,260 on at

    André Arnaud de Calavon,

    The button is located under Production control > Common > Production orders > All Production orders. Under the tab Schedule - Schedule jobs.

    User-default-2.JPG

    Job scheduling form opens and on the form we have "Default values" button.

    User-default-2.JPG

    On clicking the button another form opens i.e. Set up job scheduling. On the form we have "User default" button - this button should be only visible by the user id pjackson.

    User-default-3.JPG

    So the button "User default" on the form Set up job scheduling should be only visible and have the complete control by the user id pjackson.

  • Verified answer
    Brian Kinser Profile Picture
    815 on at

    using the security development tool it is easy to locate this button, then modify the privilege/role (that's what allows the button to be visible)....you can find what security roles / privileges are related to this button, then you can modify (or just remove) that privilege from that role. Now create a new role and add that privilege to the new role. Then for pjackson user, just add that role for that user.....now no one else but pjackson will see that button (also anybody else that you add that new role will see it if you want) What ever user you want to see this just add them to the new role

  • Verified answer
    André Arnaud de Calavon Profile Picture
    301,088 Super User 2025 Season 2 on at

    Hi D_Meethu,

    I will reveal you how I would check the security. In this case finding the related privilege/duty using the security development tool is cumbersome as you are multiple levels deep in opening forms/menu items starting from the main menu.

    The next steps will provide you the information which security objects are related.

    1) When you are the system administrator, you can right click on the last shared form and choose the option 'Personalize'.

    2) On the Personalization form, go to the Information tab and click 'Edit' behind the Form name.

    3) The AOT opens. Now find the 'User default' button in the design or design-list.

    4) Open the property window and check for the properties MenuItemType and MenuItemName.

    5) Evaluate if there are values (in this case type Action, 'ProdMultiUserDefault') . If there was no values on these properties, it was related to a button where you needed to change/review the NeededPermission property as mentioned above)

    6) Browse in the AOT for the menu-item.

    7) Right click on the selected menu-item and choose: Add-ins > Security tools > View related security roles.

    8) On this form you will see the information which roles, duties and privileges do have access to this menu-item.

    9) In my demo environment only one privilege is used. This privilege is named 'ProdMultiUserDefaultProcess'. It appears that only one menu-item is member of this privilege.

    10) You need to decide what to do. In my demo there is only one role which has access to this menu-item. Suppose there are 5 users and one needs to have this button available, I would choose to create a second role for the other 4 users. (try to avoid changing standard security objects)

    11) Duplicate the role and provide a new name, label and description. The label descriptions should be unique in all languages you are using in your environment to avoid security errors.

    12) Duplicate the duty which is also provided on the View related security roles. Then also provide a new name, label and description.

    13) Remove the privilege 'ProdMultiUserDefaultProcess' from the duplicated duty.

    14) Replace the duty on the duplicated role with the new duty.

    15) Save and compile.

    Now the already existing role can be used for user 'pjackson'. The new role with less access can be used for the other persons.

    At some steps, also the security development tool can provide some insights and can help duplicating and replacing duties.

  • Daljit Kaur Rahsi Profile Picture
    1,260 on at

    Awesome -

    Thank you Martin Dráb, Brian Kinser and André Arnaud de Calavon.

    Abdre, thank you for the complete steps and approach I should be performing in implementing the new roles for the other users.

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