WPF Window doesn't have a size property instead you can use ActualWidth
and ActualHeight
. Same way it doesn't exposes Location
also but you can use Left
and Top
properties.
All the above properties are of type double
so you need a cast to appropriate type.
System.Drawing.Size sz = new System.Drawing.Size((int)ActualWidth, (int)ActualHeight);
System.Drawing.Point loc = new System.Drawing.Point((int)Left, (int)Top);