Skip to main content

Hi there.

We are facing one problem in a project: after moving the document to a new library we need to set the document permissions. In the Add document reference wizard we are using the reference created for the moved document, but in the second screen, where we have to choose the users/groups we are facing this error:

 

SmartObject property SmartObjectName is a required property for selected method GetServiceInstanceForSmartObject. Value must be set.

 

We have tried to update to last version http://help.k2.com/kb001735, because of this fix to K2 for sharepoint: When using Document Library References to copy, move or upload a Document, using a document based on a reference was not possible.

 

Our aditional problem is that we cannot simply create another reference for the document (in the destination library) and set the permissions, because our destination libraries are dinamically, and through the wizard i have to choose the library manually.

 

Do you see any other option OOB without calling the Sharepoint rest service :

 

url: /_api/web/GetFileByServerRelativeUrl('<file relative url>')/ListItemAllFields/roleassignments/addroleassignment(principalid=<groupId>,roledefid=<targetRoleDefinitionId>)

 

 

Tia,

Best Regards.

 

 

I forgot to mention that we are using SP 2013.


Just for reference ... the problem was solved "hand-writing" the desired String ...


Reply