Sharepoint online library creation from custom template

Welcome Forums General PowerShell Q&A Sharepoint online library creation from custom template

This topic contains 4 replies, has 3 voices, and was last updated by

2 years, 10 months ago.

  • Author
  • #41272

    Points: 0
    Rank: Member

    First time poster, been finding answers on here for a bit though. Great community!

    I am trying to create a new sharepoint online library from a saved custom template. I am able to do this through the O365 portal, and I am able to create a new sharepoint online library with powershell as per this article:

    Create new document library in SharePoint Online with PowerShell

    However, I can't figure out how to call a custom template. I've found few articles referencing PS scripts against sharepoint 2010, but they don't seem to work.

    Has anyone tried this? Seems like I'm very close, but can't get it to work.

    Also – I would love to be able to feed the powershell command with new site library names from a file to bulk create many libraries from the same template with different names if someone knows how to do that?

    Any ideas?


  • #41319

    Points: 1,811
    Helping HandTeam Member
    Rank: Community Hero

    After some extensive Twitter chat with some SharePoint MVPs, it appears you can't.

  • #41392

    Points: 0
    Rank: Member

    Thanks for the quick reply Don! I appreciate your efforts and those in twitter thread that tried as well

    That was the answer I got elsewhere also, but the community has been known to find creative ways to get things done. Thanks al!

  • #41418

    Points: 86
    Rank: Member

    To add some further background to this when I used to do a lot more SharePoint work I moved away from building Lists in the GUI and started to build them all using CSOM and PowerShell with the SPPS module as this allowed me to build, test and delete them in an automated fashion and I ensured that I had the functions available to do this.

    I did start work on a function to export a list from 1 site and then import it into another site however I then got side tracked when I ended up leaving doing much SharePoint work.

    I would advise to head to the PnP PowerShell Repository and see if the guys there can expand the Get-SPOProvisioningTemplate to output only List Schemas as I was unable to get the list schema using PowerShell and CSOM though that may be due to my rustiness with CSOM more than anything else.

  • #41428

    Points: 86
    Rank: Member

    However that being said you can get some of the functionality copied between lists even in different site collections or environments (think On-Prem to SPO) using the below sample using the SPPS module as detailed in my last post.

    Hopefully that will help you get on your way .

The topic ‘Sharepoint online library creation from custom template’ is closed to new replies.

denizli escort samsun escort muğla escort ataşehir escort kuşadası escort