Wednesday, March 13, 2013

Activity Feeds and Exceptions or How to fix something that should work

During work I found following logs in event viewer:

Exception information: 
    Exception type: CrmException 
    Exception message: Could not find a web resource with name Images/refresh.png.
   at Microsoft.Crm.Application.Components.Handlers.WebResource.RetrieveWebResource(String webResourceName, String preview)
   at Microsoft.Crm.Application.Components.Handlers.WebResource.ProcessRequestInternal(HttpContext context)
   at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
   at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

I rechecked existing customization and the only Images/refresh.png was an image that was imported into the system with Activity Feeds solution. I rechecked all html and js webresources of Activity Feed Solution and I found 2 suspicious constructions in scripts:

Error was obvious – ../ was wrong part of reference to image. And solution was obvious as well. I extracted all solution component from solution, found js webresource with errors (msdyn_ActivityFeedsMentionsjsdcd634d6-1470-4b8f-8e19-89849fa559ba and msdyn_ActivityFeedsUIjs619c6362-849a-4c96-bf6f-341444117795), fixed error and archived solution back, imported to the system and error disappeared.

No comments:

Post a Comment