When the original install was done without the flag, the command to delete the file was stored in the uninstall log. It will stay there until uninstallation, and there is no method to remove it while keeping the rest. It works this way so that the uninstaller can automatically handle any changes in the set of files of your application.
Your best bet is probably to set the [Setup] section directive UninstallLogMode to overwrite. This instructs Setup to overwrite any existing uninstall log from the same application instead of appending to it. That way, if you update using an installer which does have the flag, the old entry will be removed from the log. Note that this does mean you will have to start handling changes in the set of files yourself, for example by adding [InstallDelete] or [UninstallDelete] entries for files which are no longer part of your application.
Another option is to use [Code] to back up the file before uninstall and restore it after.
In general though, installing a file that users are allowed to edit is not a good idea. Consider installing a default, non-editable file instead and having your application copy it to the actual editable settings location when no settings exist yet.
Greetings,--
You received this message because you are subscribed to the Google Groups "innosetup" group.
To unsubscribe from this group and stop receiving emails from it, send an email to innosetup+...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/innosetup/CACJXiZzO2fYNOEraM3WzUaqy4Abqs1Xttn79yAdbUx129E%2BzPA%40mail.gmail.com.