Redirect Users without any role
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-03-2023 05:54 AM
In the SPEntryPage Script Include, what do I have to edit, to redirect users without any role to the Service Portal.
The required properties are already created. I´ve managed to redirect a user with a specific role to the SP. But I also want to do this step with users who don´t have a role at all
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-03-2023 06:05 AM
you can try below code
if(!user.hasRoles())
return /sp
If my answer solved your issue, please mark my answer as ✅Correct & 👍Helpful
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-03-2023 06:12 AM
Unfortunately it doesn´t work that way
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-03-2023 06:16 AM
@Steve2000 please refer below link.
If my answer solved your issue, please mark my answer as ✅Correct & 👍Helpful
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-03-2023 06:21 AM - edited 04-03-2023 06:21 AM
I tried this, but even though, the user with the specific role doesn´t land on SP page