Hello,
Welcome to Microsoft Q&A Case.
For retrieving the properties of photo file, you can check the following steps.
1.Create a list of strings and add the identifier for each property you want to retrieve.
2.Call ImageProperties.RetrievePropertiesAsync
method, which takes this list of strings and returns a dictionary of key/value pairs.
Reference: Image MetaData
public async void Access()
{
var folder = KnownFolders.PicturesLibrary;
StorageFile imageFile = await folder.GetFileAsync("test1.jpg");
if (imageFile!=null)
{
ImageProperties props = await imageFile.Properties.GetImagePropertiesAsync();
var requests = new System.Collections.Generic.List<string>();
requests.Add("System.Photo.ISOSpeed");
IDictionary<string, object> retrievedProps = await props.RetrievePropertiesAsync(requests);
if (retrievedProps.ContainsKey("System.Photo.ISOSpeed"))
{
var exifVersion = retrievedProps["System.Photo.ISOSpeed"];
}
}
For update the properties of photo file, you can use SavePropertiesAsync() method.
ImageProperties props = await imageFile.Properties.GetImagePropertiesAsync();
var keyvalue = new KeyValuePair<string, object>("System.Photo.ISOSpeed", 100);
var properties = new List<KeyValuePair<string, object>>() { keyvalue };
await props.SavePropertiesAsync(properties);
The sample only shows the retrieval and update of “ISOSpeed” property. If you want to know more properties, please refer to the following document. System.Photo
If the response is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.