Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Registry Class Problem
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Divers
Thread ID:
00207999
Message ID:
00208195
Vues:
25
>Ed:
>
>Thanx for leading me in the right direction. The problem was lCreateKey was always false. The strange thing is there is a lCreateKey property that I set to true, but it doesn't get passed to the SetRegKey function. I had to add it to the parameter statement. In the comments for SetRegKey, it doesn't show it in the example. How would any one know?
>

Unfortunately, reading the code is required; it helps to know how the registry-related API calls work. The problem is that the SetRegKey method is really a wrapper that combines two distinct operations, opening or creating the registry key, and then creating or modifying a registry value. i don't think that MS did anyone a favor creating the method; I'd rather see two methods invoked explicitly so that the decision process was clearer. It's one reason that I keep using my own existing library rather than the FFC. I let my registry class behave in a stateful fashion, so that I can open a registry key and then set multiple registry values, using a property to keep track of the key handle.

>Regards,
>Charlie
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform