LockScreen LockScreen LockScreen LockScreen LockScreen Class


Provides properties and methods to manage the full-screen image used as the lock screen background.

public : static class LockScreen
static struct winrt::Windows::System::UserProfile::LockScreen
public static class LockScreen
Public Shared Class LockScreen
// This class does not provide a public constructor.
Windows 10 requirements
Device family
Windows Desktop Extension SDK (introduced v10.0.10240.0)
API contract
Windows.System.UserProfile.UserProfileLockScreenContract (introduced v1)


This example uses the SetImageFileAsync method of this class to set the lock screen image. The variable file is assumed to be a previously assigned image.



using namespace Windows::System::UserProfile;

This example uses the GetImageStream method of this class to retrieve the lock screen image.

IRandomAccessStream imageStream = LockScreen.GetImageStream();

auto imageStream = Windows::System::UserProfile::LockScreen::GetImageStream();


OriginalImageFile OriginalImageFile OriginalImageFile OriginalImageFile OriginalImageFile

Gets the current lock screen image.


GetImageStream() GetImageStream() GetImageStream() GetImageStream() GetImageStream()

Gets the current lock screen image as a data stream.

RequestSetImageFeedAsync(Uri) RequestSetImageFeedAsync(Uri) RequestSetImageFeedAsync(Uri) RequestSetImageFeedAsync(Uri) RequestSetImageFeedAsync(Uri)

Registers an RSS image feed to be used as a lock screen slideshow. (Windows 8.1 only)

SetImageFileAsync(IStorageFile) SetImageFileAsync(IStorageFile) SetImageFileAsync(IStorageFile) SetImageFileAsync(IStorageFile) SetImageFileAsync(IStorageFile)

Sets the lock screen image from a StorageFile object.

SetImageStreamAsync(IRandomAccessStream) SetImageStreamAsync(IRandomAccessStream) SetImageStreamAsync(IRandomAccessStream) SetImageStreamAsync(IRandomAccessStream) SetImageStreamAsync(IRandomAccessStream)

Sets the lock screen image from a data stream.

TryRemoveImageFeed() TryRemoveImageFeed() TryRemoveImageFeed() TryRemoveImageFeed() TryRemoveImageFeed()

Unregisters the image feed being used in the lock screen slideshow, stopping the slideshow. (Windows 8.1 only)

See Also