Show Dialog box at center of its parent

后端 未结 5 535
Happy的楠姐
Happy的楠姐 2020-12-28 13:14

It\'s been a mess to show a DialogBox at the center of its parent form. Here is a method to show a dialog.

I am positioning its parent to center but not able to cen

5条回答
  •  挽巷
    挽巷 (楼主)
    2020-12-28 13:35

    form1.StartPosition = FormStartPosition.CenterScreen;
    

    See http://msdn.microsoft.com/en-us/library/system.windows.forms.form.startposition(v=vs.110).aspx

提交回复
热议问题