Cannot instantiate an Com component
Publicado: Lun Abr 15, 2013 11:51 pm
Hi,
I have a Com Component, which instantiates correctly with other Harbours, e.g. the one bundled with Minigui.
But when I try to active the component inside Xailer, it returns an error.
I tried the code below, but receive the
OLE server not found
error. It's confirmed that the object is registered on the system, and is in the HKEY_CLASSES_ROOT registry section.
I've also tried Creating COM Component objects from other apps, like Excel and Word, and it was successful. But for some reason, it's not reading the object.
In the other versions of Harbour, after running CreateObject, the returned object has a ValType of 'O'. In Xailer, it ends up Undefined 'U'.
TRY
comAmziComLogicServer := GetActiveObject( sAmziComServer )
CATCH
TRY
comAmziComLogicServer := CreateObject( sAmziComServer )
CATCH
sValType := ValType( comAmziComLogicServer )
Return
END
END
I have a Com Component, which instantiates correctly with other Harbours, e.g. the one bundled with Minigui.
But when I try to active the component inside Xailer, it returns an error.
I tried the code below, but receive the
OLE server not found
error. It's confirmed that the object is registered on the system, and is in the HKEY_CLASSES_ROOT registry section.
I've also tried Creating COM Component objects from other apps, like Excel and Word, and it was successful. But for some reason, it's not reading the object.
In the other versions of Harbour, after running CreateObject, the returned object has a ValType of 'O'. In Xailer, it ends up Undefined 'U'.
TRY
comAmziComLogicServer := GetActiveObject( sAmziComServer )
CATCH
TRY
comAmziComLogicServer := CreateObject( sAmziComServer )
CATCH
sValType := ValType( comAmziComLogicServer )
Return
END
END