Martyn Bullerwell's Blog

Embedding Images into DLL's

I am sure this is already well documented, however, its something that is really very straight forward with .NET 2.0, and not clearly written about so far on the web, so here is(hopefully) a good example:


Step 1:  Embed the Resource -


Step 2:  Reference the resource with the exact name and Namespace.

Step 3: Retrieve the Embedded resource

Image.ImageUrl = Page.ClientScript.GetWebResourceUrl(typeof(_Default), "[YourNamespace].Contributor.png");

 It is that easy!!