SiteLogoImage.ThemeKey property

Retrieve the image specified in LogoImageUrl or SPWeb.SiteLogoUrl from the themed CSS folder of the site using the specified theme key

Namespace:  Microsoft.SharePoint.WebControls
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)

Syntax

'Declaration
Public Property ThemeKey As String
    Get
    Set
'Usage
Dim instance As SiteLogoImage
Dim value As String

value = instance.ThemeKey

instance.ThemeKey = value
public string ThemeKey { get; set; }

Property value

Type: System.String

Remarks

Some caveats to this property: - If the web has a SiteLogoUrl set, it will be used in lieu of LogoImageUrl. The SiteLogUrl will still be themed if it's in the allow list. - If this control is being rendered when there is no context web, then the logo image will not be themed. - If this property is set to null, then logos explicitly listed in the allow list will be themed with the site - To make a non-default logo themable, it MUST be also described in a themable CSS file using the RecolorImage theming annotation and the themeKey attribute which should match the theme key specified here.

See also

Reference

SiteLogoImage class

SiteLogoImage members

Microsoft.SharePoint.WebControls namespace