cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
MaxDonen
Level: Powered On

Powerapps + automate/flow = incompletely populated excel email attachment

I have posted a similar query in the Power Automate forums, but I figured I'd rule out any chance of my issue originating from Power Apps rather than my flow. 

 

Put simply, I use onselect() to have a button create a new collection, col_export_singleproject_costs. I then use this new collection to populate a sharepoint list, List_CostAnal. 

 

 

 

/*
To create new collection, then export collection to Sharepoint List (more steps, possibly less risky):
*/
ClearCollect(
    Col_Export_SingleProject_Costs,
    Filter(
        Col_CostAnal_SingleProject,
        Shown = true,
        Analysis_Type=Dropdown_CostRebase_PD_CostAnal.Selected.Result, 
        Project_ID exactin Col_ProjectDetails_SingleProject.ProjectCode)
);

//Empty existing records in Sharepoint list.
RemoveIf(List_CostAnal,true);



ForAll(Col_Export_SingleProject_Costs,
Patch(List_CostAnal,
{
    'Project ID': Project_ID,
    'Analysis Type': Analysis_Type,
    'Bespoke Analysis': Bespoke,
    'Bespoke Cost': Bespoke_Cost,
    'CBS123 Analysis: CBS1': CBS1,
'CBS1 Cost': CBS1_Cost,
'CBS123 Analysis: CBS2': CBS2,
'CBS2 Cost': CBS2_Cost,
'CBS123 Analysis: CBS3': CBS3,
'CBS3 Cost': CBS3_Cost,
'Elemental Analysis': Element,
'Element Cost':Element_Cost,
'Direct/Indirect Analysis: Direct Level 1': DirectLevel1,
'Direct Level1 Cost': DirectLevel1_Cost,
'Direct/Indirect Analysis: Direct Level 2': DirectLevel2,
'Direct Level 2 Cost': DirectLevel2_Cost,
'Subfacility Analysis': SubFacility,
'Subfacility Cost':Subfacility_Cost,
'Element ID Number': ID_Number,
Unit:Unit,
Quantity:Quantity,
Rate:Rate,
'% of parent/total':'% of parent/total',
Description:Description,
Notes:Notes,
'Year+Quarter obtained':YearQuarter,
'HPI Value':'HPI value'
}
));


SharepointToExcel_Test2.Run(User().Email);

 

 

 This works absolutely fine. 

 

Note the last line of code. 

SharepointToExcel_Test2.Run(User().Email) triggers a flow once the list is populated. This flow copies each row of the list into an Excel document. 

 

Once again, this all works fine. 

 

The flow then gets the excel file content and metadata, and sends the excel as an email attachment to the user. 

 

For some reason, the attached excel file is never fully populated. Some rows are always missing, and it's not a consistent number. 

 

Eg: only 24/36 intended rows populated, only 1/15 intended rows populated. 

 

Since the sharepoint list and excel doc populate correctly in sharepoint, I initially ruled out Powerapps as a cause. But I figured I may as well check I'm not doing anything wrong in Powerapps? Are there any known issues to be aware of when populating lists?

 

On the Flow side of things, I have tried delays, adding extra 'check' steps and even creating a 2 stage flow (1 flow triggers another)...no joy.  

 

So apologies if this post sounds like it shouldn't be here, but at this stage I'm just trying to cover absolutely every base. 

 

Thanks. 

 

1 ACCEPTED SOLUTION

Accepted Solutions
Microsoft v-siky-msft
Microsoft

Re: Powerapps + automate/flow = incompletely populated excel email attachment

@MaxDonen 

 

Could you please share the flow steps? so we can try to reproduce the issue you mentioned.

I never heard any limitation to flow in PowerApps.

If the share point list is populated completely, I suggest you recreate a flow triggered by a flow manually to check if the issue still remains.

Then you can confirm if the issue only happens when the flow is triggered by PowerApps or not

Sik

 

View solution in original post

2 REPLIES 2
Microsoft v-siky-msft
Microsoft

Re: Powerapps + automate/flow = incompletely populated excel email attachment

@MaxDonen 

 

Could you please share the flow steps? so we can try to reproduce the issue you mentioned.

I never heard any limitation to flow in PowerApps.

If the share point list is populated completely, I suggest you recreate a flow triggered by a flow manually to check if the issue still remains.

Then you can confirm if the issue only happens when the flow is triggered by PowerApps or not

Sik

 

View solution in original post

MaxDonen
Level: Powered On

Re: Powerapps + automate/flow = incompletely populated excel email attachment

Thanks for the response. I have looked further into the issue and it turns out that it was a detail in my Flow. I have been advised that I need to apply a few more min's delay for the flow to work correctly. 

 

Thanks anyway 🙂

Helpful resources

Announcements
thirdimage

Power Platform 24

Check it out!

thirdimage

New Badges

Check it out!

thirdimage

Power Apps Community User Group Member Badge

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

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

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