Change use role for a button click

0
Hi there, I am trying to switch the user role  through microflow using a button, eg, i need to switch from employee to HR or to other user role on a button click  and show respective pages. Thanks in advance.    
asked
3 answers
6

Hi Harsha,

You can do it by calling a microflow, and in the microflow, you can retrieve the desired user role:

eg.

[id = '[%UserRole_Administrator%]']

and then pass it to the current user account, and then show the desired page,

Let me know, if you have any issues,

Hope it  helps!!

answered
1

Hi Harsha, your approach is correct to use the Change Object to change the user role; 
however, since you want to switch the role from Employee to HR, instead of retrieving the list of User roles (although I am not sure of settings in your Retrieve action), you can choose to retrieve only the HR User role and assign it to the ‘current user’.

Once done, as Rishabh has suggested above, you would need to call the appropriate Page of the HR in the microflow. Please check the below image:


 

answered
0

 

Hi Rishabh,

 Done in this way but didn’t worked for me.

 

answered