reinstall - C# application version management -


i have c# app corresponding setup program. reads startup data registry , stores information under "environment.specialfolder.applicationdata"\myapp folder.

my question is: if make various changes code include new registry keys, should reflect in new version when re-running setup it:

  • keeps current registry keys/values
  • adds new key/value registry
  • leaves "application data" untouched

the candidates are:

  • assembly info
  • file version

if there others please let me know.

thanks

i think application should able create regestry keys. don't know if user removes them manually reset settings default. setup should install , register components. (but uninstaller should ask user if want remove settings, or keep them.)

solution a)

to avoid version-conflicts can remember version number configuration. example: program version 1.0 , 2.0 using configuration-set 1 while program version 3.0 uses configuration-set 2, because there obsolete/new settings. create sub-key in registry tree every configuration-set. "application data" can include subfolder seperated configuration sets. major advantage is, user can downgrade without problems. new versions can import old values older configuration default values.

solution b)

never delete (or change type or range) settings. add new keys. old program versions don't know them ignoring it. simple because there no different configuration versions. if saving lot of settings can become complicated, because cannot change type of setting. example have create new key change setting saving integer long integer, because old versions don't understand long integers , crash.


Comments

Popular posts from this blog

c# - SharpSVN - How to get the previous revision? -

c++ - Is it possible to compile a VST on linux? -

url - Querystring manipulation of email Address in PHP -