Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

edditing properties for files  RSS feed

 
mohamed hamdy
Ranch Hand
Posts: 72
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
can i edit properties for files to read again using an output stream, and if so, if this file has the extension jpg for example , will what i write to the fill affect how the file is displayed in Acdsee for example , my question is for any type of file.
if i can do that , then how i write to the file in order to reading these properties again.
 
Charles Rector
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Whether or not you can append your own personal properties to a file depends upon the format of the file in question. Some file types perform exhaustive checking for validity, whereas others are more lenient.
In any event, you'll want to research the file formats you're interested in dealing with. If you're looking for a mechanism which can be applied to all files, regardless of type, it may be a better option to create separate files which complement existing files.
For example, if you have an image named "moose.jpg", your program could create a counterpart for it named "moose.jpg.properties" which would be a normal text file. In your program you could then grab all the filenames in a folder and check for any matching ".properties" filenames. Any files with matches would be the ones which have custom properties specified.
 
Consider Paul's rocket mass heater.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!