SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

We have a WebPart that has a module with resources (images, css and js files).

Locally it works perfectly when deploying from VisualStudio.

In a testing server we're deploying the webpart via powershell (Uninstall-SPSolution ; Remove-SPSolution ; Add-SPSolution ; Install-SPSolution).

The module files (images) get copied to the right location, the elemets.xml with the redirection is there also.

But when trying to load the web part the new images (recently added) cannot be accessed (error 404 not found).

Does anybody know what might be happening here?

share|improve this question

You need to Deactivate/activate the feature or if you wan't to do it the right way then use FeatureUpgrading with a ApplyElementManifests element for the elements.xml with the images and then make sure the feature is upgraded

share|improve this answer
already tryed that, but still no luck – Ricardo Gomes Mar 21 '12 at 15:32
I was replying to deactivate/activate, not to the FeatureUpgrading part. Can you provide more info on that part, maybe a link. – Ricardo Gomes Mar 21 '12 at 15:42

Here is something to try :

  • Deactivate the feature
  • Retract the solution
  • delete the solution
  • Go into your site via Manage Content and Structure and verify that all of the new images are in fact deleted. If they are not gone, delete them manually. The goal is to completely eliminate all traces of the feature and to eliminate any manual tweaks that may have been done outside the feature deployment and activation process
  • Add the solution
  • Deploy the solution
  • Activate the feature
  • Now retest and try to find images that are not working and a possible pattern between them.
  • Once you have a few images that work and a few that don't go into the elements.xml file that covers the images and compare the entries between those that work and those that don't.
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.