Skip to content

Instantly share code, notes, and snippets.

@folkertsj
Created July 7, 2011 16:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save folkertsj/1069944 to your computer and use it in GitHub Desktop.
Save folkertsj/1069944 to your computer and use it in GitHub Desktop.
PageData pd = DataFactory.Instance.GetPage(GetSiteStartPage(siteId));
AccessControlList acl = pd.ACL.CreateWritableClone();
acl.Add(new AccessControlEntry(username, AccessLevel.FullAccess));
acl.Remove("Everyone");
new PageAccessControlList(pd.PageLink, acl).Save(SecuritySaveType.RecursiveModify);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment