>>Hiya.
>>
>>Is there a quick way to determin if an OLE object is registred on a system without performing CREATOBJECT() and handle the following error?
>>
>>I'm reading data from another OLE enabled app and I would like to check when I start my app so I can disable the update data feature if it's not there.
>
>Magnus,
>You could check registry. ie :
>
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
>return llRetVal
Cetin
Thanks Cetin.
Just what I was looking for.
Magnus NordinVFP MCP
"We have tested the GUI on 5-year olds. Why? Beacuse they aren't braindead!"
Michael Spindler, Apple