Microsoft Dynamics CRM 2011 Scripting Cookbook
上QQ阅读APP看书,第一时间看更新

Creating and managing other resources

JavaScript resources are not the only available resource that can be added to your solution package. Other file types can be also associated in a similar manner, including HTML pages, stylesheets, image files, as well as Silverlight controls.

Getting ready

Navigate to your solution package, and expand the Web Resources section.

How to do it...

On the Web Resources view, follow these steps:

  1. Click on New to add a new resource.
  2. In the new window, give the resource a name, a display name, and add a description if necessary.
  3. Select JPG for Type as we will be adding an image resource.
    How to do it...
  4. Click on Browse to retrieve a locally-stored image.
  5. Once the picture is selected, click on Save and then on Publish. Now your resource is added to the solution package.

    Tip

    The URL field shows a reference to how you access the resource image directly. We will be using part of that URL in scripts where we work with image resources.