PowerShell
SharePoint Online
Apply Template Tenant SharePoint Online
August 09, 2020Environment:
SharePoint Online
Tools:
SharePoint Online Management Shell
Case:
I want to apply template from SharePoint Look Book, I've tried 3 times to apply through that site directly but no luck, i got some exception messages like below:
- Exception: Access denied. You do not have permission to perform this action or access this resource.
- Exception: {"SiteId":"","SiteStatus":3,"SiteUrl":""}
I did not trace the error, it might be provisioning issue if you directly apply the template. But, I've tried another way and it works for me like below.
Solutions:
- Clone from GitHub.
- Run as Admin SharePoint Online Management Shell.
Connect-PnPOnline https://yoururl.sharepoint.com
to connect with SharePoint Online.- Then locate where you stored the (.pnp) file, in this case I applied template education.
Apply-PnPTenantTemplate -Path .\eduportal.pnp
to execute the process.- A new site created, also template has been applied.
Enjoy :)
0 comments