Adding different Images for different Themes in asp.net

To add different images at same place for different fist we need to all images in there themes e.g. (Images/Logo.png)

Now in skin files of themes we need add tag for image with skin id like this .

<asp:image runat="server" SkinId="Logo" imageurl="Images/Logo.png" />

SkinId should be same for all Image tags of different Themes & imageurl should be image which we want to use for that perticular theme.

Lets say we have two themes

BlueTheme

  1. Blue.skin
  2. StyleSheet.css
  3. Images
    1. Logo1.png

RedTheme

  1. Red.skin
  2. StyleSheet.css
  3. Images
    1. Logo2.png

So for Blue Theme in skin file Blue.skin

<asp:image runat="server" SkinId="Logo" imageurl="Images/Logo1.png" />

& for red Theme in skin file Red.skin

<asp:image runat="server" SkinId="Logo" imageurl="Images/Logo2.png" />

& in aspx page where you want to use this Image there put this

 <asp:image id="logo" runat="server" skinid="Logo" cssclass="logo" />

Like this you can have different images at same place for different themes

admin