Adding custom/new properties to any file regardless of type and extension e.g. setting 'Author' on a .txt file
I want the ability add properties and tags to a file (specifically ebook files and ebook related properties in Windows 7 but interested to go so for as many OSes as possible)
For e.g. Example.txt or Example.doc or Example.epub should all store and carry properties like 'Au开发者_JAVA百科thor', 'Publication date', 'Tags' etc..
the properties should be stored with the file itself. Such that if it is transferred to another system it retains the properties (even if i need to install 'my app' to support this function on the other machine)
How do I make this possible using .net (preferred) and what file system concepts should I learn to understand the underlying concepts and limitations to be able to implement this feature?
Any application that already does this? Thank you
Your options are:
- Make a pact with your religions version of Satan.
- NTFS streams, with the restriction that copying to any non file stream supporting file system (FAT/FAT32) will strip the meta info.
- Stick to files that have the meta info built in.
- Store the meta info in a separate file and implement a massive array of shell extensions to monitor copy operations and re-sync the .fileinfo files when the user copies them.
You can use DSOFile from Microsoft, but only works with NTFS.
http://blog.rodhowarth.com/2008/06/how-to-set-custom-attributes-file.html
精彩评论