Sometimes I am getting following error:
An item with the same key has already been added
at System.Collections.Generic.Dictionary'2.Insert(TKey key, TValue value, Boolean add) at System.Collections.Generic.Dictionary'2.Add(TKey key, TValue value)
at Microsoft.WindowsAPICodePack.Shell.PropertySystem.ShellPropertyDescriptionsCache.GetPropertyDescription(PropertyKey key) at Microsoft.WindowsAPICodePack.Shell.PropertySystem.ShellProperties.PropertySystemVideo.get_FrameWidth()
This happens randomly when I am trying to read FrameWidth
of ShellFile:
ShellFile shellFile = ShellFile.FromFilePath(_file.FullPath);
if (shellFile.Properties.System.Video.FrameWidth.Value != null) //<- fails here
Does anyone know why this could happen?