Disable close (X) button from Title bar in c#

Solution:

Just copy and paste this code snippet In your .cs code .

        protected override CreateParams CreateParams

        {

            get

            {

                CreateParams cp = base.CreateParams;

                const Int32 CS_NOCLOSE = 0x200;

                cp.ClassStyle = CS_NOCLOSE;

                return cp;

            }

        }

Next Recommended Reading C# Progress Bar Status Bar Panel