cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Anonymous
Not applicable

Use Flow to Create New List in Sharepoint Online

I know I can use flow to create a new item in a different list whenever a new item is created in the primary list, but is there any way to create an entire NEW LIST when I create an item in the primary list?

 

Example:

- I have a list "Inspection Database"

- When a new inspection is expected, I add an item here.

- Each new inspection needs a request log created (a separate list for each inspection).

 

Can I have that new request log automatically created based on a template whenever I add an item to "Inspections Database"?

6 REPLIES 6
Highlighted
Community Support
Community Support

Re: Use Flow to Create New List in Sharepoint Online

Hi @ danherring,

 

 

Creating list in sharepoint is not supported in microsoft flow currently,

I afraid that there is no way to achieve your needs in Microsoft Flow currently.

 

If you would like this feature to be added in Microsoft Flow, please submit an idea to Flow Ideas Forum:

https://powerusers.microsoft.com/t5/Flow-Ideas/idb-p/FlowIdeas

 

Regards,
Alice Zhang

Highlighted
Super User III
Super User III

Re: Use Flow to Create New List in Sharepoint Online

 I agree with @v-yuazh-msft but you might want to consider an alternate solution:

1) Create a Log list that includes a lookup column that refers to the primary list. I suggest making the lookup column a required column

2) When a new entry is created in the Log list the user will be required to select the item in the primary list to which the log entry relates

3) Create views in the Log list that group by the lookup column.  You may want to create additional views as well such as a view that only shows recent log entries, etc..

 

 

If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Scott
Highlighted
Power Participant
Power Participant

Re: Use Flow to Create New List in Sharepoint Online

Yes you can.
You need to create a Azure Function app and use powershell. You then call the azure function app in flow and it will run the powershell command to create the library or list from a template. Stp file.

Highlighted
Power Participant
Power Participant

Re: Use Flow to Create New List in Sharepoint Online

If its no need for a template you can create a list from a Send an HTTP request
Highlighted
Frequent Visitor

Re: Use Flow to Create New List in Sharepoint Online

Would you happen to know of a resource that explains either the HTTP request to create the list or the Azure function mentioned in your previous comment?

 

I have a similar need as the OP and would like to have a new custom list created.

 

 

Highlighted
Power Participant
Power Participant

Re: Use Flow to Create New List in Sharepoint Online

@rgilreath 

https://docs.microsoft.com/en-us/sharepoint/dev/sp-add-ins/working-with-lists-and-list-items-with-re...

 

https://michalguzowski.pl/create-sharepoint-list-using-flow/

 

For the Azure part you create a runbook based on powershell and then use New-PnPList to create the List where you want it.

Example of a azure runbook that creates a list in the site you input. After you created the runbook you will use the trigger called Create job in flow and call the runbook. The runbook will ask you for Title of the list and on what site you want it to be created at. You have to setup your own credentials.

 

 

{
            param (
        [Parameter(Mandatory=$true)]
        [string] 
        $Url,

        [Parameter(Mandatory=$true)]
        [string] 
        $LibraryName        
    )
    
$cred = Get-AutomationPSCredential -Name "xxxxxxx";
Connect-PnPOnline -Url $Url -Credentials $cred;
New-PnPList -Title $LibraryName -Template DocumentLibrary -OnQuickLaunch
}

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

Tech Marathon

Maratón de Soluciones de Negocio Microsoft

Una semana de contenido con +100 sesiones educativas, consultorios, +10 workshops Premium, Hackaton, EXPO, Networking Hall y mucho más!

Top Solution Authors
Top Kudoed Authors
Users online (5,230)