Windowless Activex Controls are not supported.

TeeChart for ActiveX, COM and ASP
Post Reply
DMC
Newbie
Newbie
Posts: 9
Joined: Thu Nov 04, 2004 5:00 am
Location: Clermont-Fd
Contact:

Windowless Activex Controls are not supported.

Post by DMC » Thu Nov 24, 2005 1:28 pm

Hi,

We use Teechart 7 (v 7.0.0.5) in a WinApp. The control seems to run perfectly and the corrects results are showed. But an execption is throwed, on the dispose event i suppose.

Is is logged by the application. The exception is the TargetInvocationException "Unable to get the window handle for 'AxTTchart' control. Windowless ActiveX controls are not supported.

The full exception is (in french):
"
Date : 21/11/2005 12:21:12
Système d'exploitation : Microsoft Windows NT 5.1.2600.0
Message : Impossible d'obtenir le handle de fenêtre pour le contrôle 'AxTChart'. Les contrôles ActiveX sans fenêtre ne sont pas pris en charge.
Nom : System.Windows.Forms
Pile :
at System.Windows.Forms.AxHost.MakeVisibleWithShow()
at System.Windows.Forms.AxHost.OnContainerVisibleChanged(Object sender, EventArgs e)
at System.EventHandler.Invoke(Object sender, EventArgs e)
at System.Windows.Forms.Control.OnVisibleChanged(EventArgs e)
at System.Windows.Forms.ScrollableControl.OnVisibleChanged(EventArgs e)
at System.Windows.Forms.Control.OnParentVisibleChanged(EventArgs e)
at System.Windows.Forms.Control.OnVisibleChanged(EventArgs e)
at System.Windows.Forms.ScrollableControl.OnVisibleChanged(EventArgs e)
at System.Windows.Forms.Control.OnParentVisibleChanged(EventArgs e)
at System.Windows.Forms.Control.OnVisibleChanged(EventArgs e)
at System.Windows.Forms.ScrollableControl.OnVisibleChanged(EventArgs e)
at System.Windows.Forms.Control.WmShowWindow(Message& m)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
at System.Windows.Forms.ContainerControl.WndProc(Message& m)
at System.Windows.Forms.UserControl.WndProc(Message& m)
at System.Windows.Forms.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

Exception interne :
System.Reflection.TargetInvocationException: Impossible d'obtenir le handle de fenêtre pour le contrôle 'AxTChart'. Les contrôles ActiveX sans fenêtre ne sont pas pris en charge. ---> System.NullReferenceException: La référence d'objet n'est pas définie à une instance d'un objet.
at System.Windows.Forms.AxHost.DoVerb(Int32 verb)
at System.Windows.Forms.AxHost.MakeVisibleWithShow()
--- Fin de la trace de la pile d'exception interne ---
at System.Windows.Forms.AxHost.MakeVisibleWithShow()
at System.Windows.Forms.AxHost.OnContainerVisibleChanged(Object sender, EventArgs e)
at System.EventHandler.Invoke(Object sender, EventArgs e)
at System.Windows.Forms.Control.OnVisibleChanged(EventArgs e)
at System.Windows.Forms.ScrollableControl.OnVisibleChanged(EventArgs e)
at System.Windows.Forms.Control.OnParentVisibleChanged(EventArgs e)
at System.Windows.Forms.Control.OnVisibleChanged(EventArgs e)
at System.Windows.Forms.ScrollableControl.OnVisibleChanged(EventArgs e)
at System.Windows.Forms.Control.OnParentVisibleChanged(EventArgs e)
at System.Windows.Forms.Control.OnVisibleChanged(EventArgs e)
at System.Windows.Forms.ScrollableControl.OnVisibleChanged(EventArgs e)
at System.Windows.Forms.Control.WmShowWindow(Message& m)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
at System.Windows.Forms.ContainerControl.WndProc(Message& m)
at System.Windows.Forms.UserControl.WndProc(Message& m)
at System.Windows.Forms.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)"

So can you tell me what happened and how to correct this ?

Thanks in advance.

Fred CHASSAGNE

Marc
Site Admin
Site Admin
Posts: 1272
Joined: Thu Oct 16, 2003 4:00 am
Location: Girona
Contact:

Post by Marc » Fri Nov 25, 2005 12:48 pm

Hello Fred,

I'm not immediately sure what the problem might be. TeeChart isn't a Windowless Control so I wouldn't have expected the error message.

Do you get a similar error message if you open (and close) one of the TeeChart example projects for .NET ?

What kind of project should we build here to try and recreate the problem, I see references to UserControl in the error text? Are you able to leave us an example project on news://www.steema.net/steema.public.attachments ?

With thanks.
Regards,
Marc Meumann
Steema Support

DMC
Newbie
Newbie
Posts: 9
Joined: Thu Nov 04, 2004 5:00 am
Location: Clermont-Fd
Contact:

Post by DMC » Tue Nov 29, 2005 8:31 am

Hello Marc,

Thank's for your answer. I 've try to reproduce it by open and close some demo projects. It works perfectly.

I have not able to leave you an example now, so sorry about this.

For this issue (we have an other one with v7.0.05 but i will describe it in an other post), the only thing we do is to dock the Teechart component in a user control in order to ovveride some comportment (right click menu for example).

So our chart component Inherits System.Windows.Forms.UserControl, has a teechart docked, a teechart previewer and a contextMenu on it.

I think the issue come when trying to dispose.

If you have any idea, you're welcome.

Thanks in advance.
Fred CHASSAGNE.

Post Reply