Gaby
Gaby

Reputation: 3033

User settings disappear on outlook upgrades

i'm developing an outlook plug in where users set a list of settings like credentials and site url...
I'am saving this settings in settings.settings in my windows application project.

after installing the add in the config file is set under C:\Users\ user \AppData\Local\Microsoft_Corporation\ project name \ * < outlook Version> * \user.config.

My problem is when performing update for the microsoft office outlook the outlook version changed so my add in will not be able to find the user settings.

How can i pass this problem???
Is it the best practice to save the user settings in settings.settings file?

Upvotes: 2

Views: 736

Answers (2)

Robert Gowland
Robert Gowland

Reputation: 7957

When I ran into a similar problem a while back, I found this page helpful: http://www.devx.com/dotnet/Article/33944/0/page/4.

It basically requires calling:

<your assembly>.Properties.Settings.Default.Upgrade();

Upvotes: 3

domke consulting
domke consulting

Reputation: 1022

I remember that there is a My.Settings.Upgrade method, which transfers settings between assembly updates. I'd rather use an own settings class and a path about which I decide. You can also decide to write your own upgrade routine in the case of an major application update.

Upvotes: 2

Related Questions