Re: How to save a Date to the registry?
- From: "Bill Plenge" <B_Plenge@xxxxxxxxxx>
- Date: Tue, 14 Mar 2006 22:19:47 GMT
Personally I have to admit I was an advocate against storing anything in the
registry, since it was prone to corruption and loss of the users settings.
(Face it, most users do not back up, and some of those who do neglect to
backup the registry.) However since the registry is much more stable now
then it use to be I re-evaluted that positon. Now I'm more apt to use the
registry for settings that should be unique to the user, since most people
are running XP which allows multiple accounts this seems reasonable to me.
Settings that are global to the app I still tend to put in an .ini file
though, however I've been doing this less and less. The reason being since
most XP systems give the user far too much access to such files they can
"Accidentally" delete almost any file they can read, not to mention a power
outage while rewriting the .ini will lose a lot of the settings (far safer
is to write a new .ini, delete the old and rename the new, but if an
unexpected outage occurs after the delete but before the rename the effect
is the same, though the data is in a different file the program could be
told to look for as a "last ditch effort") The same thing can happen with
regedit except fewer users are likely to use reg edit then to delete
"unneeded" files to free up disk space. Typically if an outage occurs while
writing a changed value to the registry the change never makes it to disk
(only the catch) and the old value stays or there is a "Bad" value in the
registry that the program can be set up to guard against and use a
reasonable default instead.
I still like to use .ini files during initial testing, because it's easier
for a client to e-mail me an .ini file then to export and send part of the
registry.
Just my views, hope this helps.
Best,
Bill
WebBiz wrote:
This brings up a question in my mind.
When should someone put information into the Registry as opposed to a
text or binary file?
Kev mentions putting settings and preferences into an ini file (text
file). No doubt it would make it easy for anyone to edit if need be.
My applications have all their settings in the Registry. Using
GetSetting and SaveSetting routines. Is this something I should not
have been doing?
Just curious.
What are the opinions on this?
Thanks.
Rick
"Kev" <kevinkhaw@xxxxxxxxx> wrote in message
news:1142370974.897925.220960@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
If this is a setting/preference for your application, I rather have
it saved as an ini file instead of the registry. (And please do not
save ini files to the <Windows folder>)
.
- Follow-Ups:
- Re: How to save a Date to the registry?
- From: WebBiz
- Re: How to save a Date to the registry?
- References:
- How to save a Date to the registry?
- From: Fernando Rodríguez
- Re: How to save a Date to the registry?
- From: Dag Sunde
- Re: How to save a Date to the registry?
- From: Kev
- Re: How to save a Date to the registry?
- From: WebBiz
- How to save a Date to the registry?
- Prev by Date: Re: Visual Basic reformatting code
- Next by Date: Re: Visual Basic reformatting code
- Previous by thread: Re: How to save a Date to the registry?
- Next by thread: Re: How to save a Date to the registry?
- Index(es):
Relevant Pages
|