oWsh = CREATEOBJECT("wscript.shell") *-- read a key ?oWsh.RegRead("HKEY_CURRENT_USER\Software\Microsoft\VisualFoxPro\7.0\Options\Bell") *-- write *?oWsh.RegWrite("HKEY_CURRENT_USER\Software\Microsoft\VisualFoxPro\7.0\Options\Bell", "ON")The following example shows how to read/write a registry key of type DWORD:
?oWsh.RegRead("HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\tips\DisplayInitialTipWindow") *?oWsh.RegWrite("HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\tips\DisplayInitialTipWindow", 0, "REG_DWORD")You could also use the registry class that ships with VFP, but it only supports strings.