Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我一直在寻找这个答案,但似乎找不到。我正在用 VB.Net 运行 VS2012 并有一个多形式的应用程序。当表格打开时,它们总是出现在不同的位置,如果我要同时打开它们,它们几乎会从屏幕上倾泻而下。我怎样才能让它们总是居中显示?
例如:
Form1.ShowDialog()
它应该在屏幕的中央,每次打开时都会出现在那里。
尝试:
Form1.StartupPosition = FormStartPosition.CenterScreen Form1.ShowDialog()
Form.StartPosition = FormStartPosition.CenterScreen;