Click here to Skip to main content
16,020,345 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
I need to create a create(X) option without any minimize or maximize options for my windows form application. I am trying to create a setup file and hence I require this.I put my control box property to false but the rest of the coding I don't know. Any help??
Posted
Comments
Sergey Alexandrovich Kryukov 26-Feb-13 0:22am    
Not clear what do you mean by " minimize or maximize options"? Do you want to exclude minimize/maximize/restore capabilities? It's easy, just look at the form MSDN help page. Or do you want to exclude non-client form area? Or what?
—SA
Nibu Kurian 26-Feb-13 0:32am    
yea exactly . I want to exclude the restore and minimize/maximize option and have just the close capability . I checked the msdn help but couldn't find anything specific.Just like what you see when you run a setup file(.exe)
Sergey Alexandrovich Kryukov 26-Feb-13 1:03am    
Look at Solution 1. Even though it is formulated in a sloppy manner, this is what you can do. If you did not get it, you are welcome to ask a question.
—SA

1 solution

set the minimizebox and maximizebox property of the form to false
the controlbox property to true
now the x(closebutton) is the only one left

hope it help.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900