How to prevent people to maximize window

Stoffel

Member
Joined
Dec 11, 2004
Messages
16
Location
Belgium
Programming Experience
1-3
Hiya,

I was wondering if there was a solution for this problem.

I can disable the maximize button, but if i double click on the "blue bar" (or however it is called :)) it still get maximized
 

JuggaloBrotha

VB.NET Forum Moderator
Staff member
Joined
Jun 3, 2004
Messages
4,524
Location
Lansing, MI; USA
Programming Experience
10+
on the form, change the FormBorderStyle to "Fixed Single" but they wont be able to resize the form whatsoever either, but no maximize :)
 

TPM

Well-known member
Joined
Dec 7, 2004
Messages
623
Location
CA
Programming Experience
3-5
Under the properties there's "MaximizeBox", change it to false. That will grey the maximize icon out. then use me.windowstate = formwindowstate.maximized in your onclick.

TPM
 

Stoffel

Member
Joined
Dec 11, 2004
Messages
16
Location
Belgium
Programming Experience
1-3
I tried those things, but they didn't work well

btw TPM: I was trying to not get my windowstate maximized

Now I've set my Maximumsize to the same size as my original formsize
 

Paszt

Staff member
Joined
Jun 3, 2004
Messages
1,500
Location
Raleigh, NC - USA
Programming Experience
Beginner
If you set the 'MaximizeBox' property of a form to False, this also disables the double-click on the titleBar maximize.
I'm using VS2002, but I wouldn't think this would change with 2003.
 
Top Bottom