获取图像的主题版本的路径 (如果适用)。 如果当前网站不是应用了主题,或者没有上下文网站,则返回的原始 URL。 此外,如果originalUrl或themeKey为 null 或空,则始终会返回 originalUrl。
命名空间: Microsoft.SharePoint.Utilities
程序集: Microsoft.SharePoint(位于 Microsoft.SharePoint.dll 中)
语法
声明
Public Shared Function GetThemedImageUrl ( _
originalUrl As String, _
themeKey As String _
) As String
用法
Dim originalUrl As String
Dim themeKey As String
Dim returnValue As String
returnValue = SPUtility.GetThemedImageUrl(originalUrl, _
themeKey)
public static string GetThemedImageUrl(
string originalUrl,
string themeKey
)
参数
originalUrl
类型:System.String图像的原始 URL。必须是相对于服务器的路径。
themeKey
类型:System.String主题密钥传递到 ReplaceColor 主题设置批注。
返回值
类型:System.String
应用了主题的图像,相对于服务器的 URL 或原始 URL。