0

In WPF I'm trying find the distance from my control to the bottom of the screen. I can get the position of the control using .PointToScreen() but I'm having trouble finding the distance from that point to the bottom of the screen.

I've tried using SystemParameters.WorkArea.Height, SystemParameters.VirtualScreenHeight, and SystemParameters.PrimaryScreenHeight. All of these receive a value less than the Y postion of my control probably because the scaling is at 175%. I also have a second screen that is scaled at 100%.

I would prefer a solution that uses the screen references by the PointToScreen. I also looked at System.Windows.Forms.Screen, but would prefer a WPF solution if possible.

Neil B
  • 2,096
  • 1
  • 12
  • 23

0 Answers0