in reply to Re: Installing a config file during module operation
in thread Installing a config file during module operation

Why can't you just do something like this? Use a trivial API:
get_value_names($config_name); - returns array with names of stored parameters get_value($config_name, param_name); set_value($config_name, param_name, value); clr_config($config_name);

With all due respect (and condoleances) to the people (*) who knows more about the registry than me, but why can't you just dump the values in registry keys on Windows -- and a nice config file under Unix?

It seems the obvious and trivial way of doing it? What doesn't I understand?

Update:
Just use a tie to a hash for API. No fuss, no muss. Also, add export/import to text file under Windows.

(*) Millions of people, literally :-)

Replies are listed 'Best First'.
Re: Why not use the registry on Windows?
by spiritway (Vicar) on Aug 08, 2005 at 01:32 UTC

    As a recovering Windows user, I have to say that playing with the registry is just asking for trouble. It only takes a very minor mistake to corrupt the registry, and that could leave your system unbootable. Ask me how I know this ;-)

    If you *do* want to play around with the registry, make sure you've made a good backup of it, and also review (before you begin) how to restore a corrupt registry. It can be done, but it's hard to read the help files once you've lost the ability to boot.