r***@gmail.com
2007-11-22 02:38:53 UTC
Hello,
I need to be able to handle a mouse click on an IVideoWindow
object. I am upgrading VB6 code to VB .NET and setting the message
drain to the handle doesn't seem to be working, as form clicks are not
being detected. The IVideoWindow is directly on the form, not on a
picturebox. Below is my code:
Private m_objMediaControl As QuartzTypeLib.FilgraphManager
Private m_objVideoWindow As QuartzTypeLib.IVideoWindow
....
m_objVideoWindow = m_objMediaControl
m_objMediaControl.RenderFile((sVideo)) ' name of input file
m_objVideoWindow.WindowStyle = CInt(&H6000000)
m_objVideoWindow.SetWindowPosition(CInt(objVideoWindow.Left),
m_objVideoWindow.Owner = objVideoWindow.Handle.ToInt32
m_objVideoWindow.MessageDrain = objVideoWindow.Handle.ToInt32
objVideoWindow.BringToFront()
I need to be able to handle a mouse click on an IVideoWindow
object. I am upgrading VB6 code to VB .NET and setting the message
drain to the handle doesn't seem to be working, as form clicks are not
being detected. The IVideoWindow is directly on the form, not on a
picturebox. Below is my code:
Private m_objMediaControl As QuartzTypeLib.FilgraphManager
Private m_objVideoWindow As QuartzTypeLib.IVideoWindow
....
m_objVideoWindow = m_objMediaControl
m_objMediaControl.RenderFile((sVideo)) ' name of input file
m_objVideoWindow.WindowStyle = CInt(&H6000000)
m_objVideoWindow.SetWindowPosition(CInt(objVideoWindow.Left),
m_objVideoWindow.Owner = objVideoWindow.Handle.ToInt32
m_objVideoWindow.MessageDrain = objVideoWindow.Handle.ToInt32
objVideoWindow.BringToFront()