Home > SharePoint 2010 > Web Application Scoped Resources

Web Application Scoped Resources

When you try to deploy a solution without Web Application Scoped Resources, you will get the following errors:

The solution contains no Web application scoped resource, and therefore cannot be deployed to a particular Web application. It can only be deployed globally.

If you like to deploy the solution to a web application, you need to set the Assembly Deployment Target to WebApplication instead of GlobalAssemblyCache. You can download a deployment script here.

References:

What is a “Web Application Scoped Resource?

A web scoped solution will contain files, features, and assemblies etc that are deployed to specific web applications (or All of them as selected). If there is an assembly destined for the bin directory or a feature set as WebApplication, Site or Web Scoped, then the solution deployment screen will ask you which web application to deploy the solution too (there are other triggers, e.g. App Resource Files (.resx) etc). Of course though, you may have globally deployable files in the solution (e.g. GAC located assemblies) as well as web app scoped resources.

When deploying web app scoped resources, any modifications to the bin folder, app_* folders, web.config etc will only apply to the web apps the solution has been deployed to (or all of them if selected – this option does not include Central Admin or the SSP web app!). Any newly created web apps will not receive these changes UNLESS you have also deployed files into the LAYOUTS/* folder(s) which get merged during web app creation (this is a separate topic all together).

Globally deployed resources are available to ALL web applications on the server, these tend to include farm scoped features, GAC located assemblies and files being deployed into the LAYOUTS/* folder(s).

The difference between deploying “globally” and to all content web apps depends on what you are deploying. If there are web.config changes or web application / site / web scoped features, then these cannot be deployed globally anyway – the option will not be displayed as they must be deployed to a target web application(s).

Issues Deploying SharePoint Solution Packages

Advertisements
Categories: SharePoint 2010
  1. fewlines4biju
    May 10, 2012 at 7:38 pm

    This is a nice solution, but that also sometimes do not work. You can refer this also

    http://www.fewlines4biju.com/2012/05/this-solution-contains-no-resources.html

  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: