How can I read/write application settings belonging to another assembly?

Posted on 2010-03-27
Medium Priority
Last Modified: 2013-12-17
Hey guys,

I have a solution containing two projects - a WinForms project and a Class lib project. I need to be able to read/write from/to the settings file (Settings.settings) associated with the class library project, from the WinForms project.

Note: the settings are user scoped.

Can anyone tell me how to do this?

Thanks in advance!

Question by:Chris_Harris

Accepted Solution

spule earned 2000 total points
ID: 28853173
You can make the settings public. In you Class Lib project's Properties, go to the Settings dialog and choose Access Modifier: Public. Then just access the settings from the other project through MyClassLib.Properties.Settings.

Expert Comment

ID: 28872639

I think the following article will help you:


Enjoy ! :)

Author Comment

ID: 28882540
Thanks guys,

Spule - I tried that late last night and it did not work but today it did - so much for late night programming! Have you ever used SettingsGroupNameAttribute on a settings class?

xoperator - thanks for the link :-)

Featured Post

Get your problem seen by more experts

Be seen. Boost your question’s priority for more expert views and faster solutions

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article is for Object-Oriented Programming (OOP) beginners. An Interface contains declarations of events, indexers, methods and/or properties. Any class which implements the Interface should provide the concrete implementation for each Inter…
Wouldn’t it be nice if you could test whether an element is contained in an array by using a Contains method just like the one available on List objects? Wouldn’t it be good if you could write code like this? (CODE) In .NET 3.5, this is possible…
The Relationships Diagram is a good way to get an overall view of what a database is keeping track of. It is also where relationships are defined. A relationship specifies how two tables connect to each other. As you build tables in Microsoft Ac…
Hi, this video explains a free download that you can incorporate into your Access databases, or use stand-alone for contact management. Contacts -- Names, Addresses, Phone Numbers, eMail Addresses, Websites, Lists, Projects, Notes, Attachments…
Suggested Courses
Course of the Month7 days, 4 hours left to enroll

594 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question