0
votes

I'm working with CommuniGate GIPS ActiveX-control in WPF C#. I was able to create a COM reference in my project and call the interface in my code. When i do this a new window is created by the ActiveX-control that shows my video and handles my audio.

I create the interface like this:

var plugin = new CommuniGateAVPluginGIPS.CommuniGateAVPluginGIPS();

The problem now is that i want to take some more control over that window by using it's handle, but i can't just read it out of the object.

Is it possible to get an window handle from a COM object if its not available by default?

1
What Spy++ tells? If the ActiveX is "windowless", you won't have a window handle.manuell

1 Answers

0
votes

People,

I've found my anwser. By using Win32 method FindWindow i can get the handle by searching for the window name.

Here an example.

[DllImport("User32.dll")]
public static extern IntPtr FindWindow(string lpClassName, string lpWindowName);

FindWindow(null, /*Here the window name*/);