windows-vistaregistry-virtualization

Standard location of system-wide configuration files of an app?


Since Windows Vista, our friends from Redmond are putting an end to the habit of storing configuration files in C:\Program Files\<AppName>\config.ini. Ok, they introduced Registry Virtualisation, but it's always better to fix your stuff, right?

I'm planning to fix a pre-Vista app which runs as a service, and which needs to maintain a machine-wide configuration file.

Where do I store the config file? And what would be the most portable/future-proof way of obtaining the path to that location?


Solution

  • After improving my Google-fu starting from a related question, I think I've found the definitive answer in this microsoft blog post which actually describes much more than what I originally wanted to know.