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 Apps / Flow returning wrong d...
Power Apps
Answered

Flow returning wrong data type to Powerapps

(0) ShareShare
ReportReport
Posted on by 2,407 Super User 2024 Season 1

I have added a pen input to a Powerapp. I added a Flow to save the image to a SP library. I wanted to return the filename and ID to the App so I could then Patch the ID back to the SP list that holds the remainder of the data. When I look at the return in Flow, I see the ID as a  number, which is the correct number, but it is listed as a string data type. But in the app I get an error "This data is unsupported . . ." and it is being returned as blob data  The screen shot shows the different values - the top is the app, the bottom is the flow - the file NAMES are the same, but not the IDs.
Do I need to change the data in the flow  to end up with the ID number? I tried using the Int() function, but Flow still reported it as sting data and the app still received blob data.

Flow_FileSave_05.jpg

Categories:
  • v-siky-msft Profile Picture
    Microsoft Employee on at

    Hi @BrianS .

     

    The issue is caused by the wrong definition of Response Body of JSON Schema, please change it as follows.

    {
     "type": "object",
     "properties": {
     "fileid": {
     "type": "integer"
     },
     "filename": {
     "type": "string"
     }
     }
    }

    Snipaste_2020-05-21_09-42-18.png 

    Hope this helps.

    Sik

  • BrianS Profile Picture
    2,407 Super User 2024 Season 1 on at

    I do not see a way to edit this - it tells me it is read only. I tried assigning an integer variable and sending that to Powerapp but ended up with the same result.

  • BrianS Profile Picture
    2,407 Super User 2024 Season 1 on at

    Update:

    I closed everything. I created a new Flow with the correct variable type. I started a new Powerapp and called the new flow. I am still getting the same result - the ID returns 0 rather than what the Flow sends.  The name is returned correctly.

  • BrianS Profile Picture
    2,407 Super User 2024 Season 1 on at

    I figured out how to edit the JSON. I made the change to integer, but I still get 0 returned to the Powerapp even though I see 22 in the Flow run

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

    Hi @BrianS ,

    Please share the detailed flow steps and the output of each action in Result.

    More information is needed for further assistance.

     

    If you only want to return back filename and ID of the file, could you please try with Respond to a PowerApp or flow action?

    Create a Text output, set value to DisplayName from output of Create File action. 

    Create a Number output, set value to ItemId from output of Create File action.

    Snipaste_2020-05-22_09-57-41.pngSnipaste_2020-05-22_09-56-42.pngSnipaste_2020-05-22_09-56-59.png

     

    Sik

  • Verified answer
    BrianS Profile Picture
    2,407 Super User 2024 Season 1 on at

    I tried a number of methods, but nothing I tried would pass a number or integer back to Powerapps. I ended up sending the record number as a string out of Flow and using Value in Powerapps to change it back. Nothing else I tried would work.

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 Apps

#1
11manish Profile Picture

11manish 432 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 347

#3
WarrenBelz Profile Picture

WarrenBelz 254 Most Valuable Professional

Last 30 days Overall leaderboard