Results 1 to 4 of 4

Thread: [2005] Locking a form

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Jun 2007
    Posts
    258

    [2005] Locking a form

    How do i lock the form size? so that it wont get maximized

  2. #2
    PowerPoster stanav's Avatar
    Join Date
    Jul 2006
    Location
    Providence, RI - USA
    Posts
    9,290

    Re: [2005] Locking a form

    1. Set the form's MaximizeBox = false to disable the maximize button
    2. Handle the form's resize event and check the windowstate. If its windowstate = windowstate.maximized then change it back to normal.

  3. #3
    Frenzied Member bmahler's Avatar
    Join Date
    Oct 2005
    Location
    Somewhere just west of the Atlantic
    Posts
    1,568

    Re: [2005] Locking a form

    Well, there are a couple ways to do it, you can set a maximum size and remove the maximize button or you can make a fixed form. Check out the form properties (MaximumSize, FormBorderStyle and MaximizeBox)
    Boooya
    • Visual Studio 2008 Professional
    • Don't forget to use [CODE]your code here[/CODE] when posting code
    • Don't forget to rate helpful posts!
    • If you're question was answered please mark your thread [Resolved]


    Code Contributions:
    PHP
    PHP Image Gallery v1.0PHP Image Gallery v2.0
    VB 2005
    Find Computers on a networkSimple License EncryptionSQL Server Database Access dllUse Reflection to Return Crystal ReportDocumentSilently Print PDFGeneric Xml Serailizer


    Useful Links: (more to come)
    MSDN (The first and foremost)MSDN Design Guidelines API Reference • Inno Setup CompilerInno Setup PreprocessorISTool - Fairly easy to use GUI for creating inno setup projects • Connection StringsNAnt -Automated BuildsCruise Control .NET - Frontend for automated builds

  4. #4

    Thread Starter
    Hyperactive Member
    Join Date
    Jun 2007
    Posts
    258

    Re: [2005] Locking a form

    thanks guys

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