Question

I'd like to add my own icon graphic to a feature. I found out that the ImageUrl attribute in the feature.xml definition points to the /_layouts/IMAGES folder which is out of scope for sandboxed solutions.

Is there a way to add a custom image instead of using default feature icon?

Was it helpful?

Solution

No there is unfortunatley no possibility to do that.

OTHER TIPS

Initially,even I thought that this was not possible in the sandbox. But I found a work around:

I have documented the method to add a feature image to sandbox solution here: http://community.zevenseas.com/Blogs/Vardhaman/Lists/Posts/Post.aspx?ID=11

I have an easier solution:

  1. Place the image in folder such as Style Library
  2. Write ../../Style%20Library/ as Image Url

Replacing of feature image using script which are provided using custom action is not very good solution. Image will be replaced only when feature is activated if image is deployed with module which is a part of the same feature. You can create hidden feature which should be activated on deploy to solve it.

There is another solution here. Unfortunately it also has limitations - it works fine only for the root site of the default site collection.

I confirm this works perfectly. Note that when an image is deployed in the Style Library for SharePoint 2013, a SP 2013 Sandbox solution feature Image URL property should be modified to ../../../Style%20Library , as the images folder in SP 2013 translates to /_layouts/15/images (i.e. you need to go three levels up instead of 2).

Licensed under: CC-BY-SA with attribution
Not affiliated with sharepoint.stackexchange
scroll top