PageLayout.PreviewImageUrl Property
Gets or sets the fully qualified, or absolute, URL of an associated preview image for this PageLayout object.
Namespace: Microsoft.SharePoint.Publishing
Assembly: Microsoft.SharePoint.Publishing (in Microsoft.SharePoint.Publishing.dll)
Syntax
'Declaration
Public Property PreviewImageUrl As String
Get
Set
'Usage
Dim instance As PageLayout
Dim value As String
value = instance.PreviewImageUrl
instance.PreviewImageUrl = value
public string PreviewImageUrl { get; set; }
Property Value
Type: System.String
The fully qualified, or absolute, URL of an associated preview image for this PageLayout object.
Exceptions
Exception | Condition |
---|---|
UnauthorizedAccessException | The current user does not have sufficient permissions to perform this action. |
Remarks
This image is displayed in the user interface (UI) when users are creating a PublishingPage and are selecting a PageLayout for it. This image helps identify the type of PageLayout that the user is selecting.
To save changes, you must call the PageLayout.Update method after setting this property.
The user must have edit permissions on the PageLayout object to set this value. The user must have view permissions on the PageLayout object to retrieve it initially and to get any of its property values.