Questions tagged [applicationsettingsbase]

Use this tag for questions related to the ApplicationSettingsBase Class, of C#.

From MSDN:

acts as a base class for deriving concrete wrapper classes to implement the application settings feature in Window Forms applications.

If you are using this tag, you are encouraged to use if needed.

23 questions
0
votes
1 answer

UserSettings can't serialize custom type as XML, only binary

I have a ApplicationSettingsBase object I use to save user preferences, as well as application settings. For all of my built-in types, it properly serializes to XML and I get a nice user-editable config file. However, for my custom type…
Bukowskaii
  • 31
  • 1
  • 8
0
votes
1 answer

NativeScript best way of saving favorites

I am looking for correct and decent way of storing favorites articles in my app to phone storage. I built the app with Web shop articles listed and I would like to allow users to save favorite articles to the "favorite" list. I have tried …
Maka
  • 371
  • 3
  • 14
0
votes
0 answers

Load Properties.Settings.Default from a string

I started out using Properties.Settings.Default to keep settings for my application, but now the requirements have changed, and we need to keep those settings in an SQL database instead of a file on disk. I'll have to load the xml to a string, and…
sashoalm
  • 75,001
  • 122
  • 434
  • 781
0
votes
2 answers

Why adding custom objects to List in ApplicationSettingsBase via constructor doesn't work?

This is pretty closely related to another SO question. Using the example below, could someone explain to me why adding a new List where each of Foo's properties are explicitly set causes the ApplicationSettingsBase.Save() method to correctly…
Nick Spreitzer
  • 10,242
  • 4
  • 35
  • 58
0
votes
0 answers

Custom-Settings slow load (ApplicationSettingsBase)

The first load of Custom-Settings takes around 2 seconds every time the application is started. Is there some way to accelerate it? (Or is this widely used, as suggested here, despite the speed penalty.) Here's the code: public class MySettings :…
ispiro
  • 26,556
  • 38
  • 136
  • 291
0
votes
1 answer

Why does ApplicationSettingsBase.Reset() empty the PropertyValues?

I thought the Reset() method repopulates the Settings with default values again, but it seems not to. How can I reload them with the default values? private void buttonLoadDefaultSettings_Click(object sender, EventArgs e) { …
Ashley Simpson
  • 383
  • 1
  • 6
  • 16
0
votes
0 answers

.NET: ApplicationSettingsBase unreliable?

In a larger application that makes use of Application Settings, sometimes some settings are not saved. When the following code is executed, everything works fine: Properties.Settings.Default.SomeSetting.X =…
Martin
  • 1,986
  • 15
  • 32
-1
votes
1 answer

c# How to link combobox SelectedIndex to ApplicationSettings

In Visual Studio designer (I use 2012) there is no way to link ApplicationSettings mechanism to SelectedIndex property (only Text). What workaround can be used instead? Sorry if my question was against StackOverflow rules. I searched for my…
BorisE
  • 21
  • 1
  • 5
1
2