FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;
this.ControlBox = false;
private const int CP_NOCLOSE_BUTTON = 0x200; private const int WS_CAPTION = 0x00C00000; // Removes the close button in the caption bar protected override CreateParams CreateParams { get { CreateParams myCp = base.CreateParams; // This disables the close button // myCp.ClassStyle = myCp.ClassStyle | CP_NOCLOSE_BUTTON; // this appears to completely remove the close button myCp.Style &= WS_CAPTION; return myCp; } }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)