KB-47382: Disabling buttons only for certain groups of users.

Question:

How can I disable a button only for certain groups of users (for example, to keep users not belonging to Administrators group from accessing it when  they are logged in the application)?

Solution:

To do so, you must first make sure all users and groups are properly registered in the application. After that, follow these procedures:

1 – Create an Internal Tag (Boolean) in the Viewer called Enable_User.
2 – Create a script in Viewer’s OnLogin event with the following code:

Item(“Enable_User “).Value = IsUserMemberOfGroup(“Administrators”)

3 – Create a simple link in the Enabled property of the button you wish to hide in the application with the value of Enable_User‘s tag.

Print Friendly, PDF & Email

Este artigo foi útil? Was this helpful?

Classificação média - Average rating 0 / 5. Count: 0

,

Deixe seu Comentário

Seu endereço de e-mail não será publicado. Campos marcados com asterisco são obrigatórios *