Skip to content

Latest commit

 

History

History
39 lines (29 loc) · 1.4 KB

lockscreen_getimagestream_155459607.md

File metadata and controls

39 lines (29 loc) · 1.4 KB
-api-id -api-type
M:Windows.System.UserProfile.LockScreen.GetImageStream
winrt method

Windows.System.UserProfile.LockScreen.GetImageStream

-description

Gets the current lock screen image as a data stream.

-returns

The stream that contains the lock screen image data.

-remarks

This method can be called only by apps that have set the "Picture Library Access" capability in the package manifest or by the app that set this image on the lock screen.

-examples

The following example demonstrates this method being used to retrieve the current lock screen image. For a full sample, see the Lock screen personalization sample (Windows 10).

IRandomAccessStream imageStream = LockScreen.GetImageStream();
Windows::Storage::Streams::IRandomAccessStream imageStream{
    Windows::System::UserProfile::LockScreen::GetImageStream()
};
auto imageStream = Windows::System::UserProfile::LockScreen::GetImageStream();

-see-also

LockScreen.originalImageFile, LockScreen.setImageFileAsync, LockScreen.setImageStreamAsync, Lock screen overview