Grant Roles in an Application mobile app


please help im trying to grant roles to users in a mobile app and  i have the logic below and it execute without errors. but when a try to login with that user i get an error saying incorrect password or username.Please Help

the logic of the GrantAdminRole

the assign 

Hi mlu,

so, from my understanding, you have an Employee table that is an extension of the Users table. 

To grant "Administrator" access to the user, you just need to user GrantAdministratorRole function exposed by the role.

Your issue seems to be related to the authentication credentials for your user. 

How are you creating the user? are you using EncryptPassword() for the password?
The Login action is a System Action that logs a specified end-user in the system, and it users an encrypts algorithm. That's why you need to use EncryptPassword() when creating a new user.




thanks i got it working on the web app so there was no need to create users on the mobile since they work together that what my manager wants 

thank you Vera