web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Create Items by upload...
Power Automate
Unanswered

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

(0) ShareShare
ReportReport
Posted on by 641

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.

 

My FlowMy Flow

 

Categories:
  • Tom_Slosse Profile Picture
    1,430 on at

    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

  • efialttes Profile Picture
    14,756 on at

    @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

  • v-yamao-msft Profile Picture
    Microsoft Employee on at

    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-Business/idi-p/107821?advanced=false&collapse_discussion=true&filter=location&location=idea-board:FlowIdeas&q=excel%20online%20dynamic%20content&search_type=thread

     

    Best regards,

    Mabel

     

  • panand99 Profile Picture
    641 on at

    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

  • v-yamao-msft Profile Picture
    Microsoft Employee on at

    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

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Automate

#1
Mohsin Ali Profile Picture

Mohsin Ali 299

#2
11manish Profile Picture

11manish 274 Super User 2026 Season 2

#3
Henil Profile Picture

Henil 119

Last 30 days Overall leaderboard