I\'m trying to build a Windows Forms application using C#.
How do I get the DPI in .NET?
I\'ve read before that there is DPIX and DPIY, which can be used in
Use an instance of the Graphics class. You get this using the following within your form (could be in form's Load event handler):
Graphics
Load
float dx, dy; Graphics g = this.CreateGraphics(); try { dx = g.DpiX; dy = g.DpiY; } finally { g.Dispose(); }