Forum Discussion
jk264
Sep 06, 2019Copper Contributor
Sharepoint online - copying List
Hi, I am new to Sharepoint, created a sharepoint list which i am using for Powerapps, is there a way i can create a copy of this list, some thing like save as? Also, how do i export the list schema...
- Sep 07, 2019That way of saving list templates (lest's call it "classic") should be avoided and use PnP and Site Scripts instead. The command you need to make an export of you list is the following one: https://docs.microsoft.com/en-us/powershell/module/sharepoint-pnp/get-pnpprovisioningtemplate?view=sharepoint-ps
To do the same with site scripts take a look at the following article...there you will find how to extrat the site script from a list and create a site design based on that site script: https://drewmadelung.com/powershell-for-sharepoint-site-designs-site-scripts/
WinfredLiu
Sep 07, 2019Brass Contributor
Hi jk264
In SharePoint, you can save a list as template and create a new list from that template.
You can find more details https://support.office.com/en-us/article/manage-list-templates-c3884ad1-bc49-44b8-b3d6-3bc6a01eb393
Sep 07, 2019
That way of saving list templates (lest's call it "classic") should be avoided and use PnP and Site Scripts instead. The command you need to make an export of you list is the following one: https://docs.microsoft.com/en-us/powershell/module/sharepoint-pnp/get-pnpprovisioningtemplate?view=sharepoint-ps
To do the same with site scripts take a look at the following article...there you will find how to extrat the site script from a list and create a site design based on that site script: https://drewmadelung.com/powershell-for-sharepoint-site-designs-site-scripts/
To do the same with site scripts take a look at the following article...there you will find how to extrat the site script from a list and create a site design based on that site script: https://drewmadelung.com/powershell-for-sharepoint-site-designs-site-scripts/
- jk264Sep 10, 2019Copper Contributor
Thanks jcgonzalezmartin
- WinfredLiuSep 07, 2019Brass Contributor
Can I ask why it should be avoided? What's the disadvantages of saving list templates? And the benefits of using PnP and Site Scripts?
- Sep 07, 2019Sure:
(1) Saving a list as template using the classic approach generates a STP file...the approach can be valid, but it's not recommended by Microsoft. Consider it as a deprecated feature
(2) PnP + Site Scripts is the recommended way (by Microsoft) to go to extend a SPO Site with new Columns, Content Types, Lists and Document Libraries- WinfredLiuSep 07, 2019Brass Contributor