>>Can anybody give me an example how to use getregkey()
>
>
Cemal,
>Check FFC Registry.vcx - registry class code and solution.app Read&Write reg. values.
>Sample below simply queries a Class registration.
>
>*? _IsClassRegistered("Word.Application")
>lparameters tcClass
>#DEFINE HKEY_CLASSES_ROOT -2147483648
>#DEFINE ERROR_SUCCESS 0
>
>DECLARE Integer RegOpenKey IN Win32API ;
> Integer nHKey, String @cSubKey, Integer @nResult
>
>DECLARE Integer RegCloseKey IN Win32API ;
> Integer nHKey
>
>local lnKey
>lnKey = 0
>llRetVal = ( RegOpenKey(HKEY_CLASSES_ROOT, tcClass, @lnKey) = ERROR_SUCCESS )
>if llRetVal
> RegCloseKey(lnKey)
>endif
>CLEAR DLLS
>return llRetVal
Cetin
I have found in the home(2)\classes directory registry.prg
I have learned from the code that i can use getregkey like this.
oreg.GetRegKey("ResWidth",@cValue,;
"SOFTWARE\Microsoft\VisualFoxPro\4.0\Options",;
-2147483647)
I have tried.But i dont know what the type is for cValue.
I have tried numeric and character.
But its returns only 2. but the real value for ResWidth is 1024
Thanks