You can disable the Min and Max buttons just like you would disable the close button.
Code:Private Declare Function GetSystemMenu Lib "User32" (ByVal hWnd As Integer, ByVal bRevert As Integer) As Integer Private Declare Function RemoveMenu Lib "User32" (ByVal hMenu As Integer, ByVal nPosition As Integer, ByVal wFlags As Integer) As Integer Const MF_BYPOSITION = &H400 Private Sub MDIForm_Load() RemoveMenu GetSystemMenu(hWnd, 0), 6, MF_BYPOSITION 'Disable Close RemoveMenu GetSystemMenu(hWnd, 0), 4, MF_BYPOSITION 'Disable Maximize RemoveMenu GetSystemMenu(hWnd, 0), 3, MF_BYPOSITION 'Disable Minimize End Sub




Reply With Quote