Since built in functionality for positioning forms in VB.NET are not always suitable to use I try to make my sub to do that.
But I missed something...
I had the problem with StartPosition = CenterParent
not working. I solved it calling the form with .ShowDialog()
instead of .Show()
:
' first you should set your form's Start Position as Center Parent
Private Sub button_Click(sender As Object, e As EventArgs) Handles button.Click
MyForm.ShowDialog()
End Sub