locked
Windows Files - Tags or Keywords - How to access them (Read/Write) RRS feed

  • Question

  • I am trying to have an application I am building access the tags or keywords a user might assign to a file through the file explore UI. I have been searching for hours through the documentation, but can't find anything to get me pointed in the right direction.

    From the Windows file explore people are able to add and edit tags associated with a file. Yet from my code VB.NET or C# I can't find any way to access that information for the file.

    Do you know how that might be done with VB.NET, C# or any other approaches?

    Friday, December 6, 2019 8:06 PM

All replies

  • I think you're looking for information on the Windows property system: https://docs.microsoft.com/en-us/windows/win32/properties/property-system-overview

    The tags/keywords property is probably the System.Keywords property.

    Friday, December 6, 2019 8:13 PM
  • You can read metadata with the Shell (Folder.GetDetailsOf)

    (add reference  : Microsoft Shell Controls and Automation)


    Friday, December 6, 2019 8:41 PM
  • Hi JWG1000,

    I suppose you're talking about "meta data". 
    Metadata varies by file type(file format). MP3 files have its own metadata, JPEG files have its own.
    Could you provide file extensions your application will access?

    Regards,

    Ashidacchi -- http://hokusosha.com

    Friday, December 6, 2019 11:43 PM
  • You can access the system properties from a C# UWP application using RetrievePropertiesAsync.

    Having said that, my experience when I tried it years ago was that it's not as forgiving for files with problematic properties as the native code interfaces are.

    If you're only interested in getting one property though, it'll probably be fine.

    Saturday, December 7, 2019 11:53 PM