Hello,
You can use the below code to set properties in general. However, you cannot modify the DateCreated property (System.DateCreated) since it is read-only. See this link for more information:
http://msdn.microsoft.com/en-us/library/windows/apps/br227171.aspx.
If you were trying to set properties for an image, such as LensManufacturer or a CameraManufacturer, then you could use the below code:
create_task(file->GetBasicPropertiesAsync()).then([this](BasicProperties^ stateFileProperties){
auto size = unsigned int(stateFileProperties->Size);
auto itemdate = stateFileProperties->ItemDate;
auto datemodified = stateFileProperties->DateModified;
try
{
PropertySet^ ps = ref new PropertySet();
ps->Insert("System.Photo.LensManufacturer", ref new String(L"the greatest lens manufacturer"));
ps->Insert("System.Photo.CameraManufacturer", ref new String(L"the greatest camera manufacturer"));
stateFileProperties->SavePropertiesAsync(ps);
}
catch (Platform::Exception^)
{
}
});
Thanks,
Prashant.