cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Regular Visitor

Create File in Flow Fails using PowerApps trigger

I have been fighting this for a couple days now and I'm out of ideas. I have a power app that creates a collection based on field entry.This button also passes the collection to with a flow connector using JSON. Flow parses JSON into needed variables to create an HTML file to convert to PDF. The Flow works and all the data is sitting there waiting. 

PowerAPP Button:

 

 

ClearCollect(invsort2,ShowColumns(Filter(Inventory,BOL=bolin.Text), "BOL","Trailer","Barcode","Seal","UOMtxt","skutxt","transaction_id","Wh_Location","Pallet_Count","PO","Reference","Date_Received","Handling","Storage","Cost_Total","Lot_Number"));Varcollection.Run(JSON(invsort2))

 

 

When I add any form of Create File , using SP , OneDrive Ect.. the flow will fail with the following error. 

 

 

Unable to process template language expressions in action 'Create_file' inputs at line '1' and column '2822': 'The template language expression 'json(decodeBase64(triggerOutputs().headers['X-MS-APIM-Tokens']))['$connections']['shared_onedriveforbusiness']['connectionId']' cannot be evaluated because property 'shared_onedriveforbusiness' doesn't exist, available properties are ''. Please see https://aka.ms/logicexpressions for usage details.'.

 

 

 Looking through forums I found similar errors and a number of possible resolutions. I have tried the following:

  • Export import the flow.
  • Save as on PowerApps.
  • Recreate the connector flow association thing.
  • Recreate the Flow when recreating the flow connector flow association thing royally pooched the flow.
  • Created a different flow to create file not using PowerApps Trigger."This worked"
  • Checked the flow for access to OneDrive for business connectors and credentials. remove and recreated as well.
  • Moved the file creation to the top of the Flow
  • ... 3 AM I gave my Displays the bird and used as much profanity as I could think of that I hadn't already used.

There are a couple more but I can not remember what..

I'm Missing Something.. There are multiple tutorial out there doing it the same way ... 

Any input is appreciated im still trying to fully wrap my head around PowerApps and Flow... Sorry "Power Automate".... 

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Regular Visitor

Re: Create File in Flow Fails using PowerApps trigger

Recreated everything again in the same manner and it is now working .. IDK !

View solution in original post

3 REPLIES 3
Highlighted
Super User
Super User

Re: Create File in Flow Fails using PowerApps trigger

I guess you are trying to pass the collection as you cannot extract from SP based on a filter? 

 

Looking  at your collection I would have thought you could simply use a Flow to pass the arugument bolin.Text which then does a get items on the List with teh filter BOL eq 'askinpowerapps'

 

This result could then be easly made into the HTML file

Highlighted
Regular Visitor

Re: Create File in Flow Fails using PowerApps trigger

Correct I think, Sorry for the late reply. I have an Idea as to what im doing but not a complete understanding of all of it .. Monkey see Monkey do kinda thing.Ill see if i can set it up that way.  I was working through this video  as well as a few other and they recommended collections passed with  JSON https://www.youtube.com/watch?v=HLdOO4JPZ2I . Still not sure why min does not work VS the tutorials.

 

Thanks for the input Ill play with it . 

Highlighted
Regular Visitor

Re: Create File in Flow Fails using PowerApps trigger

Recreated everything again in the same manner and it is now working .. IDK !

View solution in original post

Helpful resources

Announcements
secondImage

Demo-Extravaganza 2020

Check out these cool Power Apps & vote on your favorite!

secondImage

Robotic Process Automation

Let's talk about the solution provided by Microsoft for Robotic Process Automation (RPA)

secondImage

Community Highlights

Check out whats happening in Power Apps

secondImage

Community User Group Member Badges

FIll out a quick form to claim your community user group member badge today!

Top Solution Authors
Top Kudoed Authors
Users online (7,373)