cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
panand99
Level 10

Create Items by uploading file error - The expression "drives('')/items/filename.xlsx" is not valid.

Hi,

I want to create multiple records(Items) in sharepoint list whenever any excel file is uploaded in sharepoint library. This excel file having multiple rows and my requirement is that on each row a new item will be created.

 

I can do this if file is already uploaded in doc lib and by passing the refrence of file in flow, but how can it be possible on event basis? like when user uploaded the file, then it automatically take the handle of file and create records.

 

I tried it by using file identifier but getting error - 

 

The expression "drives('b!c3zc0Ontc6gYph34amcSaOMyRAFzdvi')/items/Bundle.xlsx" is not valid.

 

flow error.jpgMy Flow

 

5 REPLIES 5
Highlighted
Super User
Super User

Re: Create Items by uploading file error - The expression "drives('')/items/filename.xlsx" is not valid.

Hey @panand99 

 

 

I think you will have to put in a delay in your Flow because SharePoint can't find that file because it is still being uploaded sort of speak, but you already want the file name of it and that's why the Flow fails I think.

So your delay action should go between your second variable and your Excel action.

 

Hope this helps

 

Kind regards

 

Tom





Did I answer your question? Mark my post as a solution!

Proud to be a Flownaut!





Super User
Super User

Re: Create Items by uploading file error - The expression "drives('')/items/filename.xlsx" is not valid.

@panand99 

I played some months ago with Excel connector, faced the same problem; when I asked Flow Team; they confirmed Microsoft flow supported to select a file from the picker in the "Excel (Business)" connector, but choosing a dynamic content in the "File" field to select a file was not yet supported.

 

We posted this feature as an idea: https://powerusers.microsoft.com/t5/Flow-Ideas/Dynamic-content-in-File-amp-Table-inputs-Excel-Busine...

 

I haven't tested it since then, so unsure if Excel connector currently supports this feature. According to your description, it seems it is not yet implemented.

Let's hope Microsoft will priorize this feature, in the meantime if you read the comments to the idea, there is a workaround described, however, it is not valid on 100% of the cases.

 

Hope this helps





If anybody solved your question, remember to mark its post as a solution!

Proud to be a Flownaut!





Community Support Team
Community Support Team

Re: Create Items by uploading file error - The expression "drives('')/items/filename.xlsx" is not valid.

Hi @panand99 ,

 

Excel Online connector doesn’t support dynamic contents in File and Table fields. So when a dynamic content is used in these two fields, the error message you’ve mentioned will be returned.

 

Here is one of the similar requests on Flow Ideas Forum, please vote this idea at here:

https://powerusers.microsoft.com/t5/Flow-Ideas/Dynamic-content-in-File-amp-Table-inputs-Excel-Busine...

 

Best regards,

Mabel

 

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
panand99
Level 10

Re: Create Items by uploading file error - The expression "drives('')/items/filename.xlsx" is not valid.

Hi @efialttes 

 

As per post when file is moved to 'Processed' folder and then it execute another flow with 'list all rows present in a table', I want to know how we can provide the file name on it. 

I am facing issues when I provide file name/file identifier or static file name.

 

If I provided static file name then it reverts with error - The parameter 'file' has an invalid value 

 

If I provided file name or file identifier then it revers with error - The expression "drives('b!c3zc0OntVkWt0NQnzdvi')/items/file.xlsx" is not valid

 

* This flow execute on trigger when new file is created in folder

Community Support Team
Community Support Team

Re: Create Items by uploading file error - The expression "drives('')/items/filename.xlsx" is not valid.

Hi @panand99 ,

 

As I mentioned previously, it is a feature that has not been supported yet.

Please feel free vote the idea.

Thanks for your understanding.

 

Best regards,

Mabel

 

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
firstImage

Microsoft Business Applications Virtual Launch Event

Join us for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

firstImage

Watch Sessions On Demand!

Continue your learning in our online communities.

Power Platform 2019 Release Wave 2 Plan

Power Platform 2019 Release Wave 2 Plan

Features releasing from October 2019 through March 2020

thirdimage

Flow Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

fifthimage

Microsoft Learn

Learn how to build the business apps that you need

sixthImage

Power Platform World Tour

Find out where you can attend!

seventhimage

Webinars & Video Gallery

Watch & learn from the Flow Community Video Gallery!

Users Online
Currently online: 161 members 4,379 guests
Please welcome our newest community members: