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 Pages / Block File Types in Notes
Power Pages
Answered

Block File Types in Notes

(0) ShareShare
ReportReport
Posted on by 193

Hello!

 

This is for Power Apps Portals but the previous forum has been locked.

 

I want to upload an attachment to notes however want to only allow certain file types. I have read using "Accept MIME Type(s)" and "Restrict MIME Types" could resolve this so have added in the following configuration:

 

application/msword, application/vnd.openxmlformats-officedocument.wordprocessingml.document, application/vnd.ms-excel, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet, application/vnd.ms-powerpoint, application/vnd.openxmlformats-officedocument.presentationml.presentation, application/pdf, application/png, application/jpg, application/mp4, application/mpeg, application/avi

 

This however doesn't block .exe files, am I missing something?

Categories:
  • ragavanrajan Profile Picture
    7,044 Most Valuable Professional on at

    Hi @opticshrew 

    I remember there was a bug for MIME types.  You can use JS to achieve this. Maybe the following post will help from @hardikv 

     

    https://powerusers.microsoft.com/t5/Power-Apps-Portals/Portal-SharePoint-file-type-upload-restriction/m-p/1348143#M9729 

     

    Hope it helps. 
    ------------

    If you like this post, give it a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users to find it.

     

  • opticshrew Profile Picture
    193 on at

    @ragavanrajan thanks for the quick reply. I get how this would work for subgrids and other forms but unsure how I could achieve this with notes. Would I add this into the Basic Form Metadata OR onto the Basic Form itself? 

  • ragavanrajan Profile Picture
    7,044 Most Valuable Professional on at

    Try this in the custom JS section of basic form. Try it as a onload event. 

     

     

  • opticshrew Profile Picture
    193 on at

    @ragavanrajan I think I know why it's not working. We've integrated with SharePoint so even if I block the file types in System Settings it doesn't do the check. So my thoughts are these will need to be blocked on a SP side.

  • Verified answer
    ragavanrajan Profile Picture
    7,044 Most Valuable Professional on at

    @opticshrew 

     

    I can suggest you use the new File Columns in Portals instead of Notes / SharePoint attachment. 

     

    https://docs.microsoft.com/en-us/power-apps/maker/portals/configure/file-column 

     

    Hope it helps. 
    ------------

    If you like this post, give it a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users to find it.

     

  • opticshrew Profile Picture
    193 on at

    @ragavanrajan I think that's a suitable suggestion however I don't want to be adding preview features into production AND we have a requirement to upload multiple files (with no upper limit), and believe the cost of using SharePoint is cheaper (overall) than Dataverse.

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 Pages

#1
Mohsin Ali Profile Picture

Mohsin Ali 49

#2
M Bilal Khan Profile Picture

M Bilal Khan 44

#3
sannavajjala87 Profile Picture

sannavajjala87 30 Super User 2026 Season 2

Last 30 days Overall leaderboard