28
Views
5
Comments
Solved
Anonymous - in my screen
Question

Hi Expert,


I have registered my user in the user entity but still, it gives me invalid permission when I'm trying to navigate on the web screen without the anonymous being tick.

I have set my module user provider to Users and it gives me a getuserid()=0

How can i correct this problem?


Thanks and best regards.

Rank: #157
Solution

Hello JA,

Your problem is that you are not logged in with that user. You need to perform the login action.

 In order to do this, you need to use the Login system server action.


Just place this action in your logic (when you enter in the application) and before you navigate to a screen with the registered role. As soon as you execute the Login action, you will be available to navigate to the screen and the function GetUserId() will return the Id of the logged User (according to the Users entity).


Kind regards,

Rui Barradas

mvp_badge
MVP
Rank: #115

Hi JA,

Make sure that you have registered role checked on your screen and you are logged in after user is registered.

Otherwise there is no reason of getting this permission screen.

Rank: #157
Solution

Hello JA,

Your problem is that you are not logged in with that user. You need to perform the login action.

 In order to do this, you need to use the Login system server action.


Just place this action in your logic (when you enter in the application) and before you navigate to a screen with the registered role. As soon as you execute the Login action, you will be available to navigate to the screen and the function GetUserId() will return the Id of the logged User (according to the Users entity).


Kind regards,

Rui Barradas

Rank: #157

No problem, we're glad to help.

Sure thing, let us know about the new post so we can check it out after.


Kind regards,

Rui Barradas