StorageLibraryContentChangedTrigger.Create(StorageLibrary) Metodo

Definizione

Crea un trigger che verrà attivato quando un file viene modificato nella libreria specificata.

public:
 static StorageLibraryContentChangedTrigger ^ Create(StorageLibrary ^ storageLibrary);
 static StorageLibraryContentChangedTrigger Create(StorageLibrary const& storageLibrary);
public static StorageLibraryContentChangedTrigger Create(StorageLibrary storageLibrary);
function create(storageLibrary)
Public Shared Function Create (storageLibrary As StorageLibrary) As StorageLibraryContentChangedTrigger

Parametri

storageLibrary
StorageLibrary

Posizione monitorata dal trigger, ad esempio la raccolta di documenti o la raccolta di documenti.

Restituisce

Trigger che monitora la posizione specificata.

Esempio

//Get access to the library that you want to monitor 
StorageLibrary picturesLibrary = await StorageLibrary.GetLibraryAsync(KnownLibraryId.Pictures); 
var trigger = StorageLibraryContentChangedTrigger.Create(picturesLibrary);

Commenti

Per altre informazioni su come usare il trigger e un esempio di codice, vedere Monitoraggio del file system in piattaforma UWP (Universal Windows Platform) Apps

Si applica a

Vedi anche