Skip to main content

Notifications

Power Apps - Building Power Apps
Answered

Specifics of accessing the SharePoint Attachments Column

(0) ShareShare
ReportReport
Posted on by 19

I have been having trouble accessing the Attachments of a SharePoint Data source.

 

I have been receiving the error, "This Specified Column is not accessible in this context." I have one Gallery connected to a collection where it works, and another connected to a SharePoint List where it doesn't work. Both of these have the Exact Same Function in their On Select methods.

 

I've done a lot of looking and cant find the rule that govern if the Attachments are accessible or not. If anyone knows the rules and would be willing to share them, That would be very appreciated.

 

Thank you in advance.

  • Verified answer
    WarrenBelz Profile Picture
    WarrenBelz 145,580 on at
    Re: Specifics of accessing the SharePoint Attachments Column

    @AlekE ,

    As I mentioned, a Collection does not contain the attachment file content. You need to access it by looking up the data source (example it an item in a Gallery formed by this collection is selected, to view the first attachment with this in the Image of an Image control

    First(
       LookUp(
          SPList,
          ID = GalleryName.Selected.ID
        ).Attachments
    ).Value

     

    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

  • AlekE Profile Picture
    AlekE 19 on at
    Re: Specifics of accessing the SharePoint Attachments Column

    I'm not showing the attachments directly  in the gallery, I'm Collecting it into a collection and assigning it an additional value so it can be displayed on a different screen. 

  • WarrenBelz Profile Picture
    WarrenBelz 145,580 on at
    Re: Specifics of accessing the SharePoint Attachments Column

    @AlekE ,

    The strange thing is that a collection does not contain attachments - are you sure it is not the other way around? How are you trying to show the attachments in the gallery ?

  • AlekE Profile Picture
    AlekE 19 on at
    Re: Specifics of accessing the SharePoint Attachments Column

    Yes I have attachments enabled in SharePoint,

     

    The location of this error is in a Gallery with the SharePoint as it Data Source in the OnSelect method,

    I can seem to access every column except he Attachments Column

     

    I can seem to access it in another Gallery that has a Collection as a Data Source.

     

    That seems to be the only difference that I can find between the two.

  • WarrenBelz Profile Picture
    WarrenBelz 145,580 on at
    Re: Specifics of accessing the SharePoint Attachments Column

    Hi @AlekE ,

    Just checking if you got the result you were looking for on this thread. Happy to help further if not.

    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

  • WarrenBelz Profile Picture
    WarrenBelz 145,580 on at
    Re: Specifics of accessing the SharePoint Attachments Column

    Hi @AlekE ,

    Assuming you have attachments enabled in SharePoint (which is the default setting unless you have changed it), where are you getting this message ?

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

Microsoft Kickstarter Events…

Register for Microsoft Kickstarter Events…

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Announcing Forum Attachment Improvements!

We're excited to announce that attachments for replies in forums and improved…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 145,580

#2
RandyHayes Profile Picture

RandyHayes 76,287

#3
Pstork1 Profile Picture

Pstork1 64,909

Leaderboard