Private Const WS_THICKFRAME = &H40000
Private Const GWL_EXSTYLE = (-20)
Private Const GWL_STYLE = (-16)
Private Const WS_MINIMIZEBOX = &H20000
Private Const WS_MAXIMIZEBOX = &H10000
Private Declare Function SetWindowLong Lib "user32" Alias "SetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long
Private Declare Function GetWindowLong Lib "user32" Alias "GetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long) As Long
Private Sub MDIForm_Load()
Dim xl As Long
Me.Show
Debug.Print Hex(Not WS_THICKFRAME)
xl = GetWindowLong(Me.hwnd, GWL_STYLE)
xl = xl And (Not WS_THICKFRAME) And (Not WS_MINIMIZEBOX) And (Not WS_MAXIMIZEBOX)
SetWindowLong Me.hwnd, GWL_STYLE, xl
End Sub