cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Advocate I
Advocate I

Issue with "context.navigation.openFile" method

Did anyone manage to execute successfully the openFile method inside PCF control?

 

I passed a simple file object with all the required fields (fileContent, fileName, mimeType & fileSize) and object with open mode as stated in docs, but I'm always getting the error after execution.

 

Error:

  • Code: 2147746581
  • Message: "An error has occurred. Try this action again. If the problem continues, check the Microsoft Dynamics 365 Community for solutions or contact your organization's Microsoft Dynamics 365 Administrator. Finally, you can contact Microsoft Support."
1 ACCEPTED SOLUTION

Accepted Solutions
Power Apps
Power Apps

This API internally uses client API . Quick search I found this article with sample on the web , you can try -

https://blog.magnetismsolutions.com/blog/dominicjarvis/2018/03/06/how-to-save-files-in-a-supported-m...

 

else please share the code snippet and I cna have a look. 

 

hemant 

 

 

 

View solution in original post

3 REPLIES 3
Power Apps
Power Apps

This API internally uses client API . Quick search I found this article with sample on the web , you can try -

https://blog.magnetismsolutions.com/blog/dominicjarvis/2018/03/06/how-to-save-files-in-a-supported-m...

 

else please share the code snippet and I cna have a look. 

 

hemant 

 

 

 

View solution in original post

I feel so dumb now...Base64 encoding was missing in my code

No worries Ivan, this happens to all of us 🙂 . We resolve issues, unblock and move on. 

 

hemant

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

News & Announcements

Community Blog

Stay up tp date on the latest blogs and activities in the community News & Announcements.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Community Highlights

Community Highlights

Check out the Power Platform Community Highlights

Users online (7,610)