cancel
Showing results for 
Search instead for 
Did you mean: 
simuuh
Nintex Newbie

Set item permission with a collection

I want to update the item permission for an approval workflow with "Set item permission". For this, I save the approver's Accounts to an collection varibale. After this, I use this variable in the update permission item:

1. 

2. 

3. 

Error Message: "No user was found with the specified username 'DOMAIN\siw'. Permissions have not been set for this principal. Error "

Whats the problem?

System: Nintex 2013, SharePoint 2013 On-Premise

0 Kudos
Reply
16 Replies
Automation Master
Automation Master

Re: Set item permission with a collection

make sure user account exists and is not disabled.

0 Kudos
Reply
simuuh
Nintex Newbie

Re: Set item permission with a collection

All Accounts are still active.

I cant unterstand the problem because I save the user accounts (is an object?) in the collection, not only the username or alias (login name).

0 Kudos
Reply
Automation Master
Automation Master

Re: Set item permission with a collection

it need not be a user from your collection causing problem. you set permissions for other users and groups within the same action, the account causing problems might be any of these.

note as well that is if you assign a non existing or disabled account to person or group variable it doesn't throw any error. it errors out just at runtime when the user is validated against SP/AD.

0 Kudos
Reply
simuuh
Nintex Newbie

Re: Set item permission with a collection

Yeah but this are all SharePoint Groups except Initiator (Nintex Reference), Applicant (SharePoint Column, Datatytpe User).

The failed account (Message in the start topic, "DOMAIN\siw") is mine.

0 Kudos
Reply
Automation Master
Automation Master

Re: Set item permission with a collection

can you try to change configuration of collection operation that adds single accounts to collection so that instead of 'workflow data' it adds there 'value' of following formula

fn-Trim(user_varCurrentInstanceAccount)
0 Kudos
Reply
simuuh
Nintex Newbie

Re: Set item permission with a collection

there is no improvement with this change:

I also tested it with another return type, no solution.

When I add more users to the collection, in expample six, I get the same error for each user I have added.

Its looks like that a collection cant used to set item permission on the item which the workflow is running on it.

0 Kudos
Reply
Highlighted
Automation Master
Automation Master

Re: Set item permission with a collection

collection can definitelly be used in this context.

can you try to write collection content  into history log? what's format of single accounts within collection?

can you try to copy an account from history log and paste it into a people or group field in a form. does it resolve user?

can you try to set permission to user_varCurrentInstanceAccount variable instead of collection?

I would say it will fail either.

0 Kudos
Reply
simuuh
Nintex Newbie

Re: Set item permission with a collection

can you try to write collection content  into history log? what's format of single accounts within collection?

LOG Collection: DOMAIN\siw;DOMAIN\thst;DOMAIN\pba;

can you try to copy an account from history log and paste it into a people or group field in a form. does it resolve user?

Yes, I get this suggestions:

can you try to set permission to user_varCurrentInstanceAccount variable instead of collection?

I would say it will fail either.

No it works, but the History log shows the following:

0 Kudos
Reply
Automation Master
Automation Master

Re: Set item permission with a collection

hm, something gets weird with populating collection.

user accounts in collection should as well look like i:0#.w|DOMAIN\siw

is user_varCurrentInstanceAccount really variable of person or group type?

how do you populate it?

0 Kudos
Reply