Quantcast
Channel: Windows Presentation Foundation (WPF) forum
Viewing all articles
Browse latest Browse all 18858

How to get handle of an control in WPF???

$
0
0

Hi Guys

I am trying to get the handle of a canvas control using following piece of code :-

HwndSource source = (HwndSource)HwndSource.FromVisual(videoCanvas);
IntPtr hWnd = source.Handle;

but its giving same handle for canvas as well as the window.

Any other way to do it??????


Viewing all articles
Browse latest Browse all 18858

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>