I have the following formula to check if the login user is inside a group named "SRM Dev Admin User" and redirect the user to a specific start page:-
but the above formula is raising this error:-
Office365Groups.ListGroupMembers failed: The Method 'ListGroupMembers' has an invalid value for parameter 'groupid'
Any advice on this please?
Hi @johnjohn123 ,
I answered this earlier with a reference to my blog. Just get the Id of the group (as in first part of blog) and this works
If(
User().FullName in Office365Groups.ListGroupMembers(
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
).value.displayName,
AdminHomePage,
VendorScoreCard_1
)
Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.
Visit my blog Practical Power Apps
I am struggling to understand why not when it is so simple, but expanding the logic (this structure is actually in my blog)
With(
{
wGroupID:
LookUp(
Office365Groups.ListOwnedGroups().value,
displayName = "Your Group Name"
).id
},
If(
User().FullName in Office365Groups.ListGroupMembers(wGroupID).value.displayName,
AdminHomePage,
VendorScoreCard_1
)
)
Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.
Visit my blog Practical Power Apps
I tested it here and got no errors, so not sure of the issue, however if it does not work (or the ID does not as well), then you may have to re-think your structure. I use a master SharePoint list of our employees (we have about 150 in the division) and have all their details in there. A lookup on that would certainly work.
Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.
Visit my blog Practical Power Apps
This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.
Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.
User | Count |
---|---|
204 | |
71 | |
51 | |
49 | |
20 |
User | Count |
---|---|
260 | |
121 | |
85 | |
76 | |
72 |