在SizeChanged加入代码,位置和尺寸自己调整一下
Dim obj As object = e.Form.BaseForm
If obj.WindowState = 1 Then
obj.WindowState = 0
obj.Left = 0
obj.Top = 0
obj.height = 30
obj.width = 100
obj.MinimizeBox = False
Else If obj.WindowState = 2 Then
obj.WindowState = 0
obj.Left = 200
obj.Top = 200
obj.height = 300
obj.width = 400
obj.MinimizeBox = True
End If