Activate (ActiveX contol) based on COM Interop with free registration
I have a COM interop based ActiveX contol that I am trying to use with free registration. When the control is loaded, the control is inactive (does not respond to events, the control is not fully displayed, etc.).
After a lot of searching, I found that COM objects using reg-free-com are using the miscStatus attribute to set the initial state correctly. I know how to use it with comClass which corresponds to the native COM object.
1) What is the equivalent of the following clrClass element that corresponds to a COM interop object?
<comClass clsid="{qqqqqqqq-wwww-eeee-rrrr-00C0F0283628}"
tlbid="{xxxxxxxx-yyyy-zzzz-aaaa-0000F8754DA1}"
threadingModel="Both"
progid="SomeCompany.SomeOleControl"
description="Some ActiveX Control"
miscStatus="recomposeonresize,insideout,activatewhenvisible,nouiactivate" >
2) I am using the Visual FoxPro COM client. If (1) is not possible, then what can I do in VFP to activate the inactive ActiveX control. (I don't mind VB or C # input if I can use it to find the equivalent foxpro)
I have currently tried the following
this.AddObject('OleControl1', 'oleControl', 'SomeCompany.SomeOleControl')
this.OleControl1.AutoActivate = 3
this.OleControl1.Visible = .T.
this.OleControl1.SetFocus
But I get OleControl1 focus before dispatching events such as mouse clicks on its subelements. So I have to double click on it to perform the required actions, anytime it has no focus. I would like the control to behave as if the miscStatus "nouiactivate" is set.
3) Is there any other way to accomplish what I want to do?
Hans Passant, here is a list of the current Assembly.dll.manifest. The formatting in the comment made it unreadable.
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
<assemblyIdentity name="Assembly"
version="1.0.0.0" type="win32" publicKeyToken="wwwwwwwwwwwwwwww"/>
<clrClass
name="SomeCompany.SomeOleControl"
clsid="{qqqqqqqq-wwww-eeee-rrrr-00C0F0283628}"
progid="SomeCompany.SomeOleControl"
threadingModel="Both"/>
<file name="Assembly.tlb">
<typelib
tlbid="{xxxxxxxx-yyyy-zzzz-aaaa-0000F8754DA1}"
version="1.0"
helpdir=""
flags="hasdiskimage"/>
</file>
</assembly>
a source to share