I am writing a program where I want to be able to add/remove user/groups as administrator for a given Site Collection. I am using Client Object Model API for SharePoint 2010. I havent been able to find any API which would allow me to do that. Is this something which is even possible via Client Object Model? If yes how ?
You can't do that with 2010 client object model but it is now possible with 2013.
For promoting a user to Site collection admin we need to:
Having said that you can't set the
However, it is quite possible to do it via:
just looked over the code and your right it doesnt work, I had a deep look at the webservices ootb provided by sharepoint and there is no function to perform the job!! so the next solution would be to make your own webservice that does it for you!
within the webservice add:
call that method with Ajax soap call.
to create a webservice follow: