I realise this is actually a Sharepoint issue rather than a Nintex one, but i'm hoping someone here will have experienced this problem and have some idea of the cause.
I need to check if the current workflow user is a member of a named group. As there is no builtin Nintex function for this (a surprising omission) I went searching and found a recipe for writing a Nintex UDA (User defined Action) to do this. The solution is essentially the same as described in this thread.
The Nintex action seems to function as expected, but the underlying Sharepoint web service query (GetGroupCollectionFromUser) is consistently returning an empty set of groups, whichever user login name I query on.
Checking the basics-
<GetGroupCollectionFromUser xmlns="http://schemas.microsoft.com/sharepoint/soap/directory/"><Groups /></GetGroupCollectionFromUser>
Notice the empty <Groups /> element.
Has anyone seen this before and found the cause? Any hints much appreciated.
That's essientially the method i'm using, but the problem is the reply from the web service is always an empty set of groups.
My best guess as to what might be causing this would be permissions, but as i indicated above I have given the user ID that i'm using for the web service request Site Collection Admin rights, so it's hard to see that this user would be blocked from reading any group memberships.
I'm going to have a full run through the permissions settings for the user and the groups looking for any options I have missed, but at the moment it's making me scratch my head.
Please take a look at the Sharepoint group settings. There is a setting that says that members are shown only to group's members. Perhaps you have it set in that way.
No i'm afraid not.
Getting support requests through our ICT department to Nintex is difficult when it's a speculative piece of work rather than business-impacting, (which is the status of this) so for the moment it's sitting in the "unanswered question" pile.
I had to move on from this to other pieces of work, but one day I can imagine the issue coming up again and I'll still be stuck...
If you're still interested in GetGroupCollectionFromUser, you may try it as below as it worked for me:
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:dir="http://schemas.microsoft.com/sharepoint/soap/directory/">
This has bugged me as well. When I was running the webservice manually I could see some groups were being picked up but not all by a long way. On comparing groups that were appearing against those that weren't, one thing stood out.
For groups that were appearing, Site Permissions had something in it. IE Read. Those that weren't appearing were blank. As soon as I assigned a permission, they began to get picked up.
Hopefully that'll work for you as well.