Questions tagged [application-settings]

application-settings are global code or data used for configuration

Application settings are used to define key/value pairs for a broad range of data, such as:

  • default values
  • access control
  • file paths
  • protocol handlers
  • localization mappings

References

776 questions
607
votes
14 answers

How can I save application settings in a Windows Forms application?

What I want to achieve is very simple: I have a Windows Forms (.NET 3.5) application that uses a path for reading information. This path can be modified by the user, by using the options form I provide. Now, I want to save the path value to a file…
Fueled
  • 8,208
  • 9
  • 27
  • 31
203
votes
17 answers

Opening the Settings app from another app

Okay, I know that there are many question about it, but they are all from many time ago. So. I know that it is possible because the Map app does it. In the Map app if I turn off the localization for this app, it send me a message, and if I press…
FelipeDev.-
  • 2,863
  • 3
  • 19
  • 32
150
votes
10 answers

How to fix Error: "Could not find schema information for the attribute/element" by creating schema

I have a windows forms application written in VS2010 with C# and get the following errors in the app.config file: Message 4 Could not find schema information for the attribute 'name' Message 8 Could not find schema information for the attribute…
Brian McCarthy
  • 4,328
  • 15
  • 46
  • 64
93
votes
2 answers

App.config: User vs Application Scope

I have added App.config file in my project. I have created two settings from Project > Properties > Settings panel - I have noticed that when I am adding a setting, I can define scope as User or Application. - User Application If I define…
Parag Meshram
  • 7,580
  • 8
  • 47
  • 86
92
votes
13 answers

How can I display the application version revision in my application's settings bundle?

I would like to include the application version and internal revision, something like 1.0.1 (r1243), in my application's settings bundle. The Root.plist file contains a fragment like this... Type
Panagiotis Korros
  • 10,050
  • 12
  • 39
  • 41
86
votes
4 answers

Which design patterns can be applied to the configuration settings problem?

In large and complex software products managing configurable settings becomes a major pain. Two approaches I've seen to the problem are: have each component in the system load its own configuration from config files or registry settings. have a…
69
votes
4 answers

Can a spring boot @RestController be enabled/disabled using properties?

Given a "standard" spring boot application with a @RestController, eg @RestController @RequestMapping(value = "foo", produces = "application/json;charset=UTF-8") public class MyController { @RequestMapping(value = "bar") public…
Bohemian
  • 365,064
  • 84
  • 522
  • 658
53
votes
9 answers

Find current country from iPhone device

I have to get the current country in the iPhone settings. Can anyone tell me how to get the current country in iPhone application. I have to use the current country for parsing the RSS feed in which I need to pass the current country. Please help…
AppAspect
  • 4,431
  • 2
  • 27
  • 46
50
votes
5 answers

Azure connection string best practices

I have an application that I am just migrating to Azure. Currently I use web.config transformation to manage changing the database connecting string dev/staging/prod environments. How is it best to manage these multiple connection strings in Azure?
Craig
  • 34,658
  • 33
  • 108
  • 191
46
votes
3 answers

Difference between 'SpecialFolder.LocalApplicationData' and 'SpecialFolder.ApplicationData'?

On my system, %AppData% leads to ApplicationData which is C:\Users\\AppData\Roaming But there is also C:\Users\\AppData\Local And for some more confusion D:\Users\\AppData\LocalLow string local =…
Tarion
  • 14,013
  • 11
  • 61
  • 98
45
votes
8 answers

Accessing another project's settings file

Is there a way to access the settings file from a different project? For example, I have a solution that contains 2 projects (Lets call them Proj1 and Proj2). I want to access the application settings of Proj2 from Program.cs in Proj1. Is this…
KrisTrip
  • 4,673
  • 11
  • 53
  • 71
42
votes
4 answers

How do I store desktop application data in a cross platform way for python?

I have a python desktop application that needs to store user data. On Windows, this is usually in %USERPROFILE%\Application Data\AppName\, on OSX it's usually ~/Library/Application Support/AppName/, and on other *nixes it's usually…
Douglas Mayle
  • 18,173
  • 7
  • 40
  • 57
36
votes
4 answers

Ways of keeping configuration code out of logic code using Dependency Injection

How can keep all the configuration file code out of my logic code using Settings (ApplicationSettingsBase) and Dependency Injection? With configuration I mean a customer specific configuration file. Do I really have to inject a configuration class…
33
votes
4 answers

Error: 'Cannot create unknown type '{clr-namespace:NameSpace.Properties}Settings'.'

I define my settings and styles in a ResourceDictionary:
amiry jd
  • 18,602
  • 10
  • 58
  • 127
31
votes
3 answers

FileNotFoundException in ApplicationSettingsBase

When debugging an application I always get the following error when break on exception is enabled in Visual Studio. This is really bugging me, since we work with break on exception. The funny thing is, that it still works when I continue (the…
testalino
  • 5,274
  • 6
  • 31
  • 45
1
2 3
51 52