FileUpdateRequested | fileupdaterequested event

CachedFileUpdaterUI.FileUpdateRequested | fileupdaterequested event

Fires when the Windows requests a file update. This event fires once for each requested update.

Syntax


Public Event FileUpdateRequested As TypedEventHandler(Of CachedFileUpdaterUI, FileUpdateRequestedEventArgs)

Event information

Delegate TypedEventHandler<CachedFileUpdaterUI, FileUpdateRequestedEventArgs>

Remarks

If your app participates in the Cached File Updater contract, you must register for this event in your app's activated event handler where you check for ActivationKind.CachedFileUpdater. You must respond to this FileUpdateRequested event by updating the file and setting the FileUpdateRequest.Status of the request. Use the CachedFileUpdaterUI.UpdateTarget property to determine whether your app should update the version file in its repository or the locally cached copy of the file in response to the request.

You can access information about the requested update by using the FileUpdateRequestedEventArgs.Request property on the object that is passed to your FileUpdateRequested event handler. 

If you need user input to complete the update, set the FileUpdateRequest.Status to FileUpdateStatus.UserInputNeeded and complete the request. If user interaction is available, another FileUpdateRequested will fire and your app can obtain user input and complete the request.

Examples

The File picker contracts sample demonstrates how to respond to a FileUpdateRequested event.

No code example is currently available or this language may not be supported.

Both args and e (in C# and JS respectively) contain a FileUpdateRequestedEventArgs object.

Requirements (Windows 10 device family)

Device family

Universal, introduced version 10.0.10240.0 [for Xbox, see UWP features that aren't yet supported on Xbox]

API contract

Windows.Foundation.UniversalApiContract, introduced version 1.0

Namespace

Windows.Storage.Provider
Windows::Storage::Provider [C++]

Metadata

Windows.Foundation.UniversalApiContract.winmd

Requirements (Windows 8.x and Windows Phone 8.x)

Minimum supported client

Windows 8

Minimum supported server

Windows Server 2012

Minimum supported phone

Windows Phone 8.1 [Windows Runtime apps only]

Namespace

Windows.Storage.Provider
Windows::Storage::Provider [C++]

Metadata

Windows.winmd

See also

CachedFileUpdaterUI

 

 

Show:
© 2016 Microsoft