Is there a way to switch role during run time?

Hi,


Is there a way to switch role during run time?


Thanks,

Lanz

Hi Lanz,

Yes by logging out and logging in as another user with other roles. This can also be done with service actions logout and login.

Regards,

Daniel

Daniël Kuhlmann wrote:

Hi Lanz,

Yes by logging out and logging in as another user with other roles. This can also be done with service actions logout and login.

Regards,

Daniel


Hi Daniel,


What if I have multiple roles in my user account? Is there a way to choose only 1 role upon log in? 


Thanks,

Lanz

Hi,

Each Role has three actions associated: Check<role name>Role, Grant<role name>Role and Revoke<role name>Role.

Grant and Revoke can be used in code to give or take a role from the user. If the Role is not persistent (set in its properties), when given to a user it will be bound to the user only during the current session.

Cheers

Why do you want to chose a single role during login?

It is possible using grant and revoke on, non persistent roles, but it seems an odd requirement...

Cheers