473,385 Members | 1,888 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Application Settings - Stupid Me! I don't get it...

Can somebody explain hopw to store and restore settings values in .NET 2005?
I read in MSDN that "The Application Settings feature of Windows Forms makes
it easy to create, store, and maintain custom application and user
preferences on the client computer."

And then it goes on to explain that you have to create wrapper classes and
bind them to different controls etc...

I don't understand Jack! All I want to do is store the value of a variable
and restore it again, sort of like Visual Basic's GetSetting and SaveSetting
functions. They store settings in the registry, but for my application, I
cannot do that. I have to store them elsewhere.

How the h*** do I do this simple task?

TIA,
Johnny J.
Apr 18 '07 #1
2 5599
On Apr 18, 9:11 am, "Johnny Jörgensen" <j...@altcom.sewrote:
Can somebody explain hopw to store and restore settings values in .NET 2005?
I read in MSDN that "The Application Settings feature of Windows Forms makes
it easy to create, store, and maintain custom application and user
preferences on the client computer."

And then it goes on to explain that you have to create wrapper classes and
bind them to different controls etc...

I don't understand Jack! All I want to do is store the value of a variable
and restore it again, sort of like Visual Basic's GetSetting and SaveSetting
functions. They store settings in the registry, but for my application, I
cannot do that. I have to store them elsewhere.

How the h*** do I do this simple task?

TIA,
Johnny J.
Right click the project file and open its properties. Click on the
settings tab and on the pane that opens click create settings file.

Add your settings. In code, you read and write them via
Properties.Settings.Default.

eg. control.BackColor = Properties.Settings.Default.MyBackColor;
Properties.Settings.Default.MyBackColor = Color.Blue;

Properties.Settings.Default.Save to save the settings.

HTH
Andy

Apr 18 '07 #2
Does thi shelp?

http://www.codeproject.com/csharp/ReadWriteXmlIni.asp

"Johnny Jörgensen" wrote:
Can somebody explain hopw to store and restore settings values in .NET 2005?
I read in MSDN that "The Application Settings feature of Windows Forms makes
it easy to create, store, and maintain custom application and user
preferences on the client computer."

And then it goes on to explain that you have to create wrapper classes and
bind them to different controls etc...

I don't understand Jack! All I want to do is store the value of a variable
and restore it again, sort of like Visual Basic's GetSetting and SaveSetting
functions. They store settings in the registry, but for my application, I
cannot do that. I have to store them elsewhere.

How the h*** do I do this simple task?

TIA,
Johnny J.
Apr 18 '07 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Frank Wilson | last post by:
Tom, It sounds to me like ASP, not ASP.NET is handling the request for WebForm1.aspx. This is most likely an IIS config issue that may have been caused by order of installation or...
1
by: Cristian | last post by:
Hi I have some trouble (on only one developer computer) with the application settings functions... I have posted to the Microsoft.Public.vstudio.setup group but they couldn't help me and asked...
1
by: UnaCoder | last post by:
Hi, I noticed that this particular object is only accessable if the IE security setting "Initialize and and script ActiveX controls not marked as safe" is enabled. Does windows maintain this list...
16
by: eSolTec, Inc. 501(c)(3) | last post by:
Thank you in advance for any and all assistance. I'm looking for a way to programmatically retrieve the following if possible: Windows Installation Key or COA from the registry Windows installed...
0
by: steve | last post by:
I am using vb.net 2005 Express Edition. Application Settings would be a very useful thing, as a global program database that persists; if only it would work! Does anyone know a hack or a...
0
by: md | last post by:
Hi all, I have a simple VB.net application, which I create and publish using VB 2005 Express. When I install it on the target computer, this application needs to be run both from the Start...
2
by: Robert Dufour | last post by:
Its easyb to change user leve settings but how do you change application level settings in code. Apparently it seems it can't be done. Duhhh. Anybody manage a workaround? Thanks for any help....
3
by: Andy Fish | last post by:
Hi, I am trying to figure out how to use asp.net membership providers for my vs2005 web project. unfortunately the only walkthrough in MSDN uses the "Web Site Administration Tool" to configure...
1
by: =?Utf-8?B?UmF5IE1pdGNoZWxs?= | last post by:
Hello, I've done this type of thing many times before so I know it works, but for some reason it's not working in this particular application. In an event handler I save some values into the...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.