Skip to main content
Fixed the text
Source Link
Ola Ström
  • 5.5k
  • 6
  • 31
  • 51

How do I center a window onscreenon the screen in C# & WinForms?

I need a way to center the current window on the screen. 

So for example, if a user pushes a button, I want the window to center itself onscreenon the screen. 

I know you can use the startposition property, but I cannot figure out a way to use that other than when the application first starts up. 

So how do I center the form on the screen?

How do I center a window onscreen in C#?

I need a way to center the current window. So for example, if a user pushes a button, I want the window to center itself onscreen. I know you can use the startposition property, but I cannot figure out a way to use that other than when the application first starts up. So how do I center the form on the screen?

How do I center a window on the screen in C# & WinForms?

I need a way to center the current window on the screen. 

So for example, if a user pushes a button, I want the window to center itself on the screen. 

I know you can use the startposition property, but I cannot figure out a way to use that other than when the application first starts up. 

So how do I center the form on the screen?

Active reading [<http://en.wikipedia.org/wiki/C_Sharp_%28programming_language%29>]
Source Link
Peter Mortensen
  • 31.4k
  • 22
  • 110
  • 134

How do I center a window onscreen in c#C#?

How do I center a window onscreen in c#C#?

I need a way to center the current window. So for example, if a user pushes a button, I want the window to center itself onscreen. I know you can use the startposition property, but I cannot figure out a way to use that other than when the application first starts up. So how do I center the form on the screen?

How do I center a window onscreen in c#?

I need a way to center the current window. So for example, if a user pushes a button, I want the window to center itself onscreen. I know you can use the startposition property, but I cannot figure out a way to use that other than when the application first starts up. So how do I center the form on the screen?

How do I center a window onscreen in C#?

I need a way to center the current window. So for example, if a user pushes a button, I want the window to center itself onscreen. I know you can use the startposition property, but I cannot figure out a way to use that other than when the application first starts up. So how do I center the form on the screen?

edited tags
Link
Andrew Orsich
  • 53.8k
  • 17
  • 142
  • 134
Source Link
Sean
  • 8.8k
  • 16
  • 45
  • 50
Loading