Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
elliott-pd
Regular Visitor

File Upload in Custom Visual

I've had a client request come up which requires a file to be uploaded to us as part of daily operations.

 

Our users currently login to Power BI to use the reports we are providing, having a separate stand-alone webpage/app which they also have to login to isn't ideal.

 

I am wondering if we can embed a file uploader as part of a custom visual. I have played around with custom visuals a little bit, and it is simple enough to create a form upload or ajax upload inside a custom visual but I have run into a bit of a brick wall around "No 'Access-Control-Allow-Originheader is present" errors. At this point, I'm not sure if this is due to me doing something wrong or because the custom visual is being run out of a sandboxed iframe which has a null Origin header. 

 

Has anyone else ever attempted anything like this? Or is this something that is not possible from inside a custom visual?

1 ACCEPTED SOLUTION
v-viig
Community Champion
Community Champion

Your backend server must allow Access-Control-Allow-Origin to be used along with Power BI.

This requred as we use the sandboxed iframe for custom visuals.

 

Ignat Vilesov,

Software Engineer

 

Microsoft Power BI Custom Visuals

pbicvsupport@microsoft.com

View solution in original post

4 REPLIES 4
v-viig
Community Champion
Community Champion

Your backend server must allow Access-Control-Allow-Origin to be used along with Power BI.

This requred as we use the sandboxed iframe for custom visuals.

 

Ignat Vilesov,

Software Engineer

 

Microsoft Power BI Custom Visuals

pbicvsupport@microsoft.com

Thanks for your response Ignat.

The CORS configuration on the server was incorrect, at some point between local dev and deployment to a testing environment the CORS configuration got messed up. Having fixed that I was able to get a solution working.

Hi @elliott-pd, can you explain how you got this working? I am having a similar requirement for upload/download, but it's impossible to access the local device. Thanks in advance!

I'm happy to hear that Smiley Happy

 

Ignat Vilesov,

Software Engineer

 

Microsoft Power BI Custom Visuals

pbicvsupport@microsoft.com

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors