Unable to get the window handle ... Windowless ActiveX controls are not supported

A

Adam Benson

Hello,

This exception :

System.InvalidOperationException was caught
Message="Unable to get the window handle for the 'AxMOSServer' control.
Windowless ActiveX controls are not supported."
Source="System.Windows.Forms"
StackTrace:
at System.Windows.Forms.AxHost.EnsureWindowPresent()
at System.Windows.Forms.AxHost.InPlaceActivate()
at System.Windows.Forms.AxHost.TransitionUpTo(Int32 state)
at System.Windows.Forms.AxHost.CreateHandle()
at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
at System.Windows.Forms.AxHost.EndInit()
at Omnibus.G3.Automation.TX.MOS.MOSAXProxy.SetupMosActiveX() in
C:\CCViews\dev_1.3_MOS\G3Automation\TX\MOS\MOSLink\MOSAXProxy.cs:line 62
at Omnibus.G3.Automation.TX.MOS.MOSAXProxy..ctor() in
C:\CCViews\dev_1.3_MOS\G3Automation\TX\MOS\MOSLink\MOSAXProxy.cs:line 33
at Omnibus.G3.Automation.TX.MOS.MOSLink.InitMosActiveX() in
C:\CCViews\dev_1.3_MOS\G3Automation\TX\MOS\MOSLink\MOSLink.cs:line 168
at Omnibus.G3.Automation.TX.MOS.MOSLink..ctor(String channelName) in
C:\CCViews\dev_1.3_MOS\G3Automation\TX\MOS\MOSLink\MOSLink.cs:line 45
at Omnibus.G3.Automation.TX.MOS.frmMOSLink..ctor(String channelName)
in C:\CCViews\dev_1.3_MOS\G3Automation\TX\MOS\MOSLink\frmMOSLink.cs:line 55
at Omnibus.G3.Automation.TX.MOS.Program.Main(String[] args) in
C:\CCViews\dev_1.3_MOS\G3Automation\TX\MOS\MOSLink\Program.cs:line 41
InnerException:

has appeared on my system. The ActiveX was built aeons ago using VB6, I
believe. It has not been touched since. The app that uses it builds OK
(VS2008), the Active X registers OK but I get the above runtime error on
startup.

The app and ActiveX in question have run quite happily for a while on XP and
may even have run OK on x64 OS's (not sure on that.) Anyway, just upgraded
my machine to Win 7 x64 and the ActiveX registered just fine, ran the app up
and I get this. I've tried using EditBin /NXCOMPAT:No to no avail.

I'm totally out of ideas. Does anyone know the answer? If you do will you
let me know please :)

Thanks,

Adam.
 
C

Colbert Zhou [MSFT]

Hello Adam,

A quick research turns out a similar issue described in the following KB,
http://support.microsoft.com/kb/814736

That situation is ActiveX user control is put on the MDI UI so that it
cause ActiveX to be destroyed. This looks like the same problem there.

By the way, we are migrating newsgroup support to forum. So if the above KB
article does not resolve the issue, to get further help, I suggest to post
it in Windows Forum or Visual C# forum. You can find the link from the MSDN
Priority Subscriber Support page
http://msdn.microsoft.com/en-us/subscriptions/aa974230.aspx


Best regards,
Ji Zhou
MSDN Online Community Support
 
A

Adam Benson

OK, thanks Colbert.

I'll give this a try and I'll start using the forums instead.

Kind Regards,

Adam.
===========
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top