Registry vs. INI file for storing user configurable application settings

前端 未结 13 1790
天涯浪人
天涯浪人 2020-12-02 16:37

I\'m a new Windows programmer and I\'m not sure where I should store user configurable application settings. I understand the need to provide a user friendly means for the

13条回答
  •  北荒
    北荒 (楼主)
    2020-12-02 17:07

    The registry is optimized for quick access and easy update, and it's the only way to do certain Windows-specific things like associating with an extension. And you can ignore the argument about deleting a single directory to uninstall your program - Windows Vista won't let you modify files in the Program Files directory, so your config will need to go in a different folder anyway.

    There's a general guideline for Windows programming - do things the way Microsoft expects you to, and your life will be a lot easier.

    That said, I can see the appeal of the INI file, and I wouldn't blame anyone for considering it.

提交回复
热议问题