Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / New Users / March 2006

Tip: Looking for answers? Try searching our database.

Best Practices: Resources vs. Settings

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Michael - 13 Mar 2006 19:15 GMT
Can anyone provide some direction as to what types of information
should be put in the project's resources vs. the project's Settings.

(ie. Properties.Resources and Properties.Settings)

As I see, Settings can store both User and Application specific
settings of virtually any object type.  Resources is limited to
Strings, Images, Icons, Audio, and Files and its scope is
assembly-wide.

Clearly, user options should be stored as User settings in the Settings
files.  On the other end, the Application icon should be stored in the
Resources file.

But what do you do with configuration information such as
"DatabaseConnectionTimeout?"
It could go as a Application scoped Setting, or it could be a assembly
resource.

I seem to be leaning to using Settings for most configuration
information.

Does anyone have an opinion?
Dmytro Lapshyn [MVP] - 14 Mar 2006 09:05 GMT
Michael,

"DatabaseConnectionTimeout" is definitely a Setting - the user might want to
adjust it. As a rule of thumb, anything possibly adjustable by the user
(even though you might have no UI to adjust it so far) should go into
Settings. Resources are just a convenient way to store program data within a
single executable file and they facilitate localization. UI strings, images,
icons, sounds are all good examples of Resources - you generally do not
expect the user to change any of these, and practically any of these types
of data might need localization.

> Can anyone provide some direction as to what types of information
> should be put in the project's resources vs. the project's Settings.
[quoted text clipped - 19 lines]
>
> Does anyone have an opinion?
Michael - 14 Mar 2006 16:31 GMT
Great, pretty much what I was thinking.  Thank you for answering.

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.