私は Windows Phone 8.1(RT) ベースのプロジェクトに取り組んでおり、作成された日付に基づいてファイルのリストを表示したいと考えています。このリンクのコードを試したところ、「System.NotImplementedException」が発生しました。
また、私のインテリセンスは、Windows Phone 8.1 には実装されていないことを示唆しています。つまり、クエリオプションを使用できないということですか、それとも代替手段はありますか? コード:
StorageFolder picturesFolder = KnownFolders.PicturesLibrary;
// Get the files in the user's Pictures folder and sort them by date.
StorageFileQueryResult results =
picturesFolder.CreateFileQuery(CommonFileQuery.OrderByDate);
// Iterate over the results and print the list of files
// to the Visual Studio Output window.
IReadOnlyList<StorageFile> sortedFiles =
await results.GetFilesAsync();
foreach (StorageFile item in sortedFiles)
{
Debug.WriteLine(item.Name + ", " + item.DateCreated);
}