Click here to Skip to main content
15,917,320 members
Home / Discussions / C#
   

C#

 
AnswerRe: plz make a easy project 4 me Pin
Christian Graus9-May-06 10:35
protectorChristian Graus9-May-06 10:35 
GeneralRe: plz make a easy project 4 me Pin
Colin Angus Mackay10-May-06 0:47
Colin Angus Mackay10-May-06 0:47 
GeneralRe: plz make a easy project 4 me Pin
Qasimsha15-May-06 10:04
Qasimsha15-May-06 10:04 
GeneralRe: plz make a easy project 4 me Pin
Colin Angus Mackay15-May-06 10:57
Colin Angus Mackay15-May-06 10:57 
JokeRe: plz make a easy project 4 me Pin
Office Lineman9-May-06 11:24
Office Lineman9-May-06 11:24 
QuestionCmdLoadFromResource method Pin
TheEagle9-May-06 10:14
TheEagle9-May-06 10:14 
QuestionDisabling the Close (X) command in Windows Pin
TheJudeDude9-May-06 9:58
TheJudeDude9-May-06 9:58 
AnswerRe: Disabling the Close (X) command in Windows Pin
Christian Graus9-May-06 10:36
protectorChristian Graus9-May-06 10:36 
GeneralRe: Disabling the Close (X) command in Windows Pin
TheJudeDude9-May-06 18:15
TheJudeDude9-May-06 18:15 
GeneralRe: Disabling the Close (X) command in Windows Pin
Christian Graus10-May-06 10:06
protectorChristian Graus10-May-06 10:06 
AnswerRe: Disabling the Close (X) command in Windows Pin
User 17164929-May-06 10:38
professionalUser 17164929-May-06 10:38 
GeneralRe: Disabling the Close (X) command in Windows Pin
TheJudeDude9-May-06 18:16
TheJudeDude9-May-06 18:16 
GeneralRe: Disabling the Close (X) command in Windows Pin
User 171649210-May-06 0:00
professionalUser 171649210-May-06 0:00 
AnswerRe: Disabling the Close (X) command in Windows Pin
Luis Alonso Ramos9-May-06 17:48
Luis Alonso Ramos9-May-06 17:48 
I didn't understand your question very well, but if you only want to disable the Close button on your C# form, just add this property to your Form:
class MyForm : Form
{
    ...
 
    protected override CreateParams CreateParams
    {
        get
        {
            CreateParams createParams = base.CreateParams;
            createParams.ClassStyle |= 0x200;  // CS_NOCLOSE
            return createParams;
        }
    }
 
    ...
}
I hope this helps!

Luis Alonso Ramos
Intelectix
Chihuahua, Mexico

Not much here: My CP Blog!
GeneralRe: Disabling the Close (X) command in Windows Pin
TheJudeDude9-May-06 18:17
TheJudeDude9-May-06 18:17 
QuestionC# winsock getdata problem Pin
_tasleem9-May-06 9:30
_tasleem9-May-06 9:30 
QuestionDefining DataType to DataColumn Pin
NaNg152419-May-06 9:14
NaNg152419-May-06 9:14 
QuestionNetwork Traffic Pin
SoftcodeSoftware9-May-06 9:08
SoftcodeSoftware9-May-06 9:08 
AnswerRe: Network Traffic Pin
Ravi Bhavnani9-May-06 10:41
professionalRavi Bhavnani9-May-06 10:41 
GeneralRe: Network Traffic Pin
SoftcodeSoftware9-May-06 11:13
SoftcodeSoftware9-May-06 11:13 
QuestionCustom collections with DataGridView Pin
Wjousts9-May-06 8:13
Wjousts9-May-06 8:13 
QuestionRemoving white spaces from an ArrayList Pin
Rizwan Rathore9-May-06 7:47
Rizwan Rathore9-May-06 7:47 
AnswerRe: Removing white spaces from an ArrayList Pin
cshivaprasad9-May-06 7:51
cshivaprasad9-May-06 7:51 
AnswerRe: Removing white spaces from an ArrayList Pin
Wjousts9-May-06 8:04
Wjousts9-May-06 8:04 
AnswerRe: Removing white spaces from an ArrayList Pin
Christian Graus9-May-06 10:37
protectorChristian Graus9-May-06 10:37 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.