cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
ajyendra24
Frequent Visitor

imported PCF solution error

Hi Experts,

Whenever I imported PCF solution I got this error:

 

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. : Microsoft.Crm.Tools.ImportExportPublish.ImportCustomControlException: CustomControl with name d365crnr.DataRangeControl failed to import with error: Webresource content size is too big. ---> Microsoft.Crm.CrmException: Webresource content size is too big.

 

Anyone face this issue?

6 REPLIES 6
rajyraman
MVP

I have seen this error happen if the webresource size is greater than 5MB. I usually minify my scripts and try to get it under the limit. I don't know whether there is a way to increase this limit.

At this time there is no way to increase the 5MB limit.  It is possible to build the control in Release mode that will minify the JavaScript file for you.

As part of the MSBuild pass in the parameter '/p:configuration=release' or if you are using VS2017/2019, set the configuration to Release.

May be too late to reply. But it seems that it is possible to reduce the bundle.js file size by using following command when you build custom control

msbuild /p:pcfbuildmode=production

 

This will tell webpack to build js in production mode. Also it generates unmanaged solution which you can import on your dev environment.

 

Thank you

I feel like i ran into this issue early on and fixed it by upping the value for "File size limit for attachments" which also affects the size of WebResources and annotations.

 

--Rick

 

AdvancedSettings.pngAdmin.pngSystemSettigns.pngEmailSettings.png

 

 

This helped...! thanks

 

DianaBirkelbach
Super User
Super User

In case FluentUI is used, usually the reason for a big bundle size (even minimized) is importing the whole library instead of taking only the needed components. In that case, maybe my blog can help to keep a small bundle size: https://dianabirkelbach.wordpress.com/2020/07/27/fluentui-granular-imports/

Kind regards,

Diana

Kind regards,
Diana
----------
Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Microsoft Ignite 768x460.png

Find your focus

Explore the latest tools,training sessions,technical expertise, networking and more.

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Welcome Super Users.jpg

Super User Season 2

Congratulations, the new Super User Season 2 for 2021 has started!

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.

Users online (2,982)