I am using the following CSOM code to get the checked out files without any version

using (context)
                List list = context.Web.Lists.GetById(new Guid("List id as string"));
                 var  checkedOutFiles = list.GetCheckedOutFiles();
                 context.Load(checkedOutFiles, c => c.Include(i => i.CheckedOutBy, i => 
                    context.ExecuteQuery(); ;
                catch (Exception ex)
                  // exception in case of read only site collections: Access denied
                   // working fine for others 

It is working fine for all libraries in all subsites in site collections which have isReadOnly=false, But in case IsReadOnly=true , I am getting an access denied error.

For those site collections in "IsReadOnly"= true , I am having no trouble reading properties for a site,subsite, groups, permissions,user,items etc.

My ACS token has full control app only permission to all the site collections in the tenant

1 Answer 1


As per Microsoft support. This is by design! Any change would require a "Feature change" request


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.