Results 1 to 5 of 5

Thread: Stop the resize?

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Jan 2002
    Posts
    448

    Stop the resize?

    how would i stop the resize. i want to make a limet on how small they can make the form?

  2. #2
    Stuck in the 80s The Hobo's Avatar
    Join Date
    Jul 2001
    Location
    Michigan
    Posts
    7,256
    A cheap, but easy way to do it would be to pop some code in the Form_Resize event:

    VB Code:
    1. Private Sub Form_Resize()
    2.   If Me.Width < 2000 Then
    3.     Me.Width = 2000
    4.   End If
    5.   If Me.Height < 2000 Then
    6.     Me.Height = 2000
    7.   End If
    8. End Sub
    My evil laugh has a squeak in it.

    kristopherwilson.com

  3. #3

    Thread Starter
    Hyperactive Member
    Join Date
    Jan 2002
    Posts
    448
    is there a better way because that is how i was doing it

  4. #4
    Stuck in the 80s The Hobo's Avatar
    Join Date
    Jul 2001
    Location
    Michigan
    Posts
    7,256
    I've seen examples on www.planet-source-code.com before. Look there.
    My evil laugh has a squeak in it.

    kristopherwilson.com

  5. #5
    PowerPoster
    Join Date
    Jan 2001
    Location
    Florida
    Posts
    3,216
    Originally posted by Nucleus
    try here:
    See here: http://www.mvps.org/vbnet/index.html...minmaxinfo.htm
    this is great but when I minimize my form to the tray, then try to bring the form back into focus the code on that site doesn't let me?

    why? Does the subclassing take over?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width