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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Automate
Suggested Answer

Flow doesn't work

(0) ShareShare
ReportReport
Posted on by 37
Hello,
 
i have a problem with a flow, that won't run... Crazy is that the flow works in test-case with powerapps on my PC but not in Live-Use on a mobile device.... 
 
Situation:
I have a Powerapp that calls a flow...  here is the code of a timer on a printscreen (name: LADUSI Printscreen) in the app:
 
If(
    LAUDSIIO = false;
    Office365Outlook.SendEmailV2(
        "123@test.de";
        "PowerApp WA";
        "Druck";
        {
            Attachments: Table(
                {
                    Name: "PowerApp WA.pdf";
                    ContentBytes: PDF(
                        'LADUSI Printscreen';
                        {
                            Orientation: PaperOrientation.Portrait;
                            Size: PaperSize.A4;
                            Margin: "20px"
                        }
                    )
                }
            )
        }
    ));;

    Office365Outlook.SendEmailV2(
        "456@test.de";
        "PowerApp LADUSI";
        "SICHERUNG";
        {
            Attachments: Table(
                {
                    Name: LADUSI_TR_Nr&".pdf";
                    ContentBytes: PDF(
                        'LADUSI Printscreen';
                        {
                            Orientation: PaperOrientation.Portrait;
                            Size: PaperSize.A4;
                            Margin: "20px"
                        }
                    )
                }
            )
        }
    );;
LAUDSI_Neu.Run(varGUID;LADUSI_TR_Nr;{file:{name:LADUSI_TR_Nr&".pdf";contentBytes:PDF(
                    'LADUSI Printscreen';
                    {
                        Orientation: PaperOrientation.Portrait;
                        Size: PaperSize.A4;
                        Margin: "20px"
                    }
                )}});;
ResetForm(Form3_1);;
Reset(ComboBox3);;
Reset(ComboBox5);;
Reset(TextInputCanvas4_1);;
Reset(TextInputCanvas3_1);;
Reset(TextInputCanvas5);;
Reset(TextInputCanvas6_1);;
Reset(TextInputCanvas7_1);;
Reset(Toggle2_6);;
Reset(Toggle2_5);;
Reset(Toggle2_4);;
Reset(cb_LaduSiFormschhinten_2);;
Reset(cb_LaduSiFormschrechts_2);;
Reset(cb_LaduSiFormschlinks_2);;
Reset(cb_LaduSiFormschvorne_2);;
Reset(cb_LaduSi_Besenrein_2);;
Reset(cb_LaduSi_Zurrgurte_2);;
Reset(cb_LaduSi_Zurrpunkte_2);;
Reset(cb_LaduSi_Boardwdef_2);;
Reset(ti_LaduSi_RungenLifehlt_2);;
Reset(cb_LaduSi_RungenLifehltalle_2);;
Reset(cb_LaduSi_SteckbLi_2);;
Reset(cb_Ladusi_RungenLi_2);;
Reset(ti_LaduSi_RungenRefehlt_2);;
Reset(cb_LaduSi_RungenRefehltalle_2);;
Reset(cb_LaduSi_SteckbRe_2);;
Reset(cb_Ladusi_RungenRe_2);;
Reset(cb_LaduSi_BWLi_2);;
Reset(cb_LaduSi_BWRe_2);;
Reset(PenInput2_1);;
Reset(Toggle2_7);;
Reset(PenInput3);;
Reset(TextInputCanvas2_1);;
Clear(colLADUSIBilder);;
Set(
    varErfolg;
    LADUSI_Mobile
);;
Navigate(Erfolgreich;ScreenTransition.Fade)
Here is the flow...
 
 
And this is the Flow with Error:
 Error Message:  

InvalidTemplate
Unable to process template language expressions in action 'Anlage_hinzufügen' inputs at line '0' and column '0': 'The template language expression 'triggerBody()['file']['contentBytes']' cannot be evaluated because property 'file' doesn't exist, available properties are 'text, text_1'. Please see https://aka.ms/logicexpressions for usage details.'.
 
 
Sorry for the long post :) 
 
Has anyone an idea what could be the problem?
Categories:
I have the same question (0)
  • Suggested answer
    SudeepGhatakNZ Profile Picture
    14,394 Most Valuable Professional on at
    Can you please post the output of your trigger.
    It seems the attached file is not getting through.
     
  • DennisSch Profile Picture
    37 on at
    Hi,
     
    yes, it seems there is no file but i don't understand why.
     
    In Edit-Mode on PC it works, on mobile device not.
     
    {
        "headers": {
            "Cache-Control": "no-store, no-cache",
            "Accept": "*/*",
            "Accept-Encoding": "gzip,deflate",
            "Accept-Language": "de-DE",
            "Expect": "100-continue",
            "Host": "prod-96.westeurope.logic.azure.com",
            "Max-Forwards": "10",
            "User-Agent": "okhttp/4.11.0",
            "x-ms-user-agent": "PowerApps/3.24121.8 (android Player; AppName=e34eeb00-f3fd-44b2-a299-61464b6f914b)",
            "x-ms-client-session-id": "8cf237a6-651d-4e7a-bc54-a8166c7c2cff",
            "x-ms-client-request-id": "df35a379-f475-49da-a492-d46b14a5a618",
            "x-ms-client-environment-id": "/providers/Microsoft.PowerApps/environments/default-d0ccde64-0ce8-4cb4-a78c-7a59521c2d45",
            "x-ms-client-tenant-id": "d0ccde64-0ce8-4cb4-a78c-7a59521c2d45",
            "x-ms-client-app-id": "/providers/Microsoft.PowerApps/apps/e34eeb00-f3fd-44b2-a299-61464b6f914b",
            "x-ms-client-object-id": "e11a0c51-2ff8-41d8-89a4-2a01c827f3a7",
            "x-ms-client-region": "europe",
            "X-MS-APIM-Referrer": "https://default-d0ccde64-0ce8-4cb4-a78c-7a59521c2d45.07.common.europe.azure-apihub.net/apim/logicflows/89e1f9b512aa4139a60198710bbd1e0c/triggers/manual/run?api-version=2015-02-01-preview",
            "x-ms-flavor": "Production",
            "x-ms-gateway-object-id": "",
            "X-MS-APIM-Referrer-Prefix": "https://default-d0ccde64-0ce8-4cb4-a78c-7a59521c2d45.07.common.europe.azure-apihub.net/apim/logicflows/89e1f9b512aa4139a60198710bbd1e0c",
            "X-MS-APIM-Callback": "https://europe-001.consent.azure-apim.net",
            "x-ms-user-id": "e11a0c51-2ff8-41d8-89a4-2a01c827f3a7",
            "x-ms-user-name": "XXX, XXX",
            "x-ms-user-name-encoded": "RWNrcm9kdCwgTWljaGFlbA==",
            "x-ms-user-email": "X.XXX@XXX.de",
            "x-ms-user-email-encoded": "TS5FY2tyb2R0QGhlbmdzdC5kZQ==",
            "x-ms-user-timestamp": "2024-12-16T13:13:35.6725520Z",
            "X-Forwarded-For": "80.146.187.214, 20.86.93.33:15300",
            "X-ARR-LOG-ID": "df35a379-f475-49da-a492-d46b14a5a618",
            "CLIENT-IP": "20.86.93.33:15300",
            "DISGUISED-HOST": "prod-96.westeurope.logic.azure.com",
            "X-SITE-DEPLOYMENT-ID": "flowfe-prod-am-rp00-app-01",
            "WAS-DEFAULT-HOSTNAME": "flowfe-prod-am-rp00-app-01.flow-prod-am-rp00-ase-01.p.azurewebsites.net",
            "X-Forwarded-Proto": "https",
            "X-AppService-Proto": "https",
            "X-ARR-SSL": "2048|256|CN=Microsoft Azure RSA TLS Issuing CA 07, O=Microsoft Corporation, C=US|CN=westeurope.logic.azure.com, O=Microsoft Corporation, L=Redmond, S=WA, C=US",
            "X-Forwarded-TlsVersion": "1.2",
            "X-Original-URL": "/workflows/bb322cc2a15943c899354f40587ccdf9/triggers/manual/paths/invoke?api-version=2016-06-01&sp=%2Ftriggers%2Fmanual%2Frun&sv=1.0&sig=h9hj_fNzbxAppi7hihcE-FBGi6Fe5tFExG-QF8dgFLM",
            "X-WAWS-Unencoded-URL": "/workflows/bb322cc2a15943c899354f40587ccdf9/triggers/manual/paths/invoke?api-version=2016-06-01&sp=%2Ftriggers%2Fmanual%2Frun&sv=1.0&sig=h9hj_fNzbxAppi7hihcE-FBGi6Fe5tFExG-QF8dgFLM",
            "Content-Length": "73",
            "Content-Type": "application/json"
        },
        "body": {
            "text": "30ec0158-2d25-44a8-859b-732e7799f503",
            "text_1": "427657  426710"
        }
    }
  • Suggested answer
    Garima_PowerPlatform Profile Picture
    170 on at
    Hi
     

    Troubleshooting Steps:

    • Check Flow Inputs and Outputs:

      • Ensure that the inputs to the flow, particularly the attachments or files, are being passed correctly. Specifically, check the structure of the data being sent to the flow.
    • Flow Action Configuration:
      • In your flow step (Anlage_hinzufügen), ensure that:
        • The file object exists and has both name and contentBytes properties.
        • The object structure being passed matches the expected format.
    • Flow Data Debugging:
      • Add a Compose step before the problematic step to debug the flow data. Use the expression triggerBody() to inspect the inputs and ensure the structure is correct:
        triggerBody()
    • Attachment Handling:
      • When creating the PDF and attaching it, ensure that the structure matches what is expected by the flow:
        powerapps
         
        Table({Name: "PowerApp WA.pdf";ContentBytes: PDF('LADUSI Printscreen';{Orientation: PaperOrientation.Portrait;Size: PaperSize.A4;Margin: "20px"})})
    • ContentBytes Property:
      • Ensure that the flow is receiving the contentBytes correctly from Power Apps. Check if there’s an issue with how the PDF() function or attachment data is passed between Power Apps and the flow.
    • Reset the Flow:
      • Ensure that if data is being reset or cleared, those steps aren't interfering with the attachment process. For example, Clear(colLADUSIBilder) might be removing necessary data if it affects the file structure.
    • Flow Permissions:
      • Ensure that the flow has necessary permissions to handle attachments. Check if any changes in permissions or access levels have occurred recently.
    Please click Does this answer your question if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it a Like.
     
  • DennisSch Profile Picture
    37 on at
     
    Thank you for your answer I checked every position but. I couldn't solve the problem...  The problem is, in the creation mode the flow works but in live mode it doesn't work.
     
    BR
    Dennis
     

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 501 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 323 Moderator

#3
abm abm Profile Picture

abm abm 237 Most Valuable Professional

Last 30 days Overall leaderboard