I am trying to keep my form from being resized below 6000 x 7365. When the user goes below the size I want, the form temporarly get set to the smaller size and then gets reset with the code below. Is there any way to keep the form going smaller then what I want or at least keep the user from seeing the resizing.
Code:Private Sub Form_Resize() frmMain.AutoRedraw = False Call LockWindowUpdate(frmMain.hWnd) If (frmMain.Width < 6000) Or (frmMain.Height < 7365) Then frmMain.Width = 6000 frmMain.Height = 7365 Call LockWindowUpdate(0) frmMain.AutoRedraw = True Exit Sub End If ' Resize rest of controls here... Call LockWindowUpdate(0) frmMain.AutoRedraw = True End Sub




Reply With Quote