cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
DynamicsNinja
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
HemantG
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
HemantG
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
PA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

Power Query PA Forum 768x460.png

Check it out!

Did you know that you can visit the Power Query Forum in Power BI and now Power Apps

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

R2 (Green) 768 x 460px.png

Microsoft Dynamics 365 & Power Platform User Professionals

DynamicsCon is a FREE, 4 half-day virtual learning experience for 11,000+ Microsoft Business Application users and professionals.

Users online (1,308)