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 / Problem with attachment
Power Apps
Answered

Problem with attachment

(0) ShareShare
ReportReport
Posted on by

Hello,

if created a app with a code for attachment + sending a mail in cc to the requester. 

I use the formula

{Attachments:AddColumns(RenameColumns(AttachmentControl.Attachments,"Value","ContentBytes"),"@odata.type",""),Cc:User().Email,Importance:"Normal"})

but now i have the problem that the attachment doesn't appear on the mail but is does appear in the Sharepoint list. 

The formula worked before without the Cc:User().Email.

How can i solve this?

 

Thanks for the help.

 

Categories:
  • WarrenBelz Profile Picture
    156,714 Most Valuable Professional on at

    Hi @MDR26 ,

    Try with the Cc first

    {
     Cc: User().Email,
     Attachments:
     AddColumns(
     RenameColumns(
     AttachmentControl.Attachments,
     "Value",
     "ContentBytes"
     ),
     "@odata.type",
     ""
     ),
     Importance:"Normal"
    }

     

    Please click Accept as solution 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 Thumbs Up.

    Visit my blog Practical Power Apps

  • MDR26 Profile Picture
    on at

    Hi,

    When I test it myself it works perfectly but when someone else makes a request the attachment does not come through in the mail.

     

     

  • Verified answer
    WarrenBelz Profile Picture
    156,714 Most Valuable Professional on at

    @MDR26 ,

    I just ran this with four attachments in a test control and got emails with all attachments in both my personal email (sent to) and my work account (cc'd to)

    Office365Outlook.SendEmailV2(
     "myemailhere@emailprovider.com",
     "Testing Attach",
     "Here are your attachments",
     {
     Cc: User().Email,
     Attachments: AddColumns(
     RenameColumns(
     AttachTest.Attachments,
     "Value",
     "ContentBytes"
     ),
     "@odata.type",
     ""
     ),
     Importance: "Normal"
     }
    )

    There is something else wrong here as the syntax is correct. Please re-check all of your references.

     

    Please click Accept as solution 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 Thumbs Up.

    Visit my blog Practical Power Apps

     

  • MDR26 Profile Picture
    on at

    @WarrenBelz 

    Meanwhile, I tested everything again and the strange thing is that some users' attachments get through via mail and others do not.

  • WarrenBelz Profile Picture
    156,714 Most Valuable Professional on at

    @MDR26 ,

    Sorry I do not have an answer for that from a Power Apps perspective. You might have to look into if there is something different in their mail setup.

  • Navishamun11 Profile Picture
    60 on at

    Hello,

     

    I am new to PowerApps and I am getting the below error when I hover these formula in the formula bar.

     

    Office365Outlook.SendEmailV2(Concat(ComboBox4.SelectedItems,Mail,";"), TextInput1.Text, RichTextEditor1.HtmlText,{Attachments: AddColumns(RenameColumns(AttachmentControl.Attachments,"Value","ContentBytes"),"@odata.type","")})

     

    Navishamun11_0-1687360211549.png

    The value is not changing to ContentBytes. Am I missing somethng here. 

     

    Navishamun11_1-1687360412543.png

     

  • Verified answer
    WarrenBelz Profile Picture
    156,714 Most Valuable Professional on at

    Hi @Navishamun11 ,

    Your error seems to be the Mail reference selected from the Combo Box

  • Navishamun11 Profile Picture
    60 on at

    Thank you so much @WarrenBelz. Yes, It was the mail reference. It's working fine now.

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 352 Super User 2026 Season 2

#2
M Bilal Khan Profile Picture

M Bilal Khan 323

#3
Mohsin Ali Profile Picture

Mohsin Ali 226

Last 30 days Overall leaderboard