Question...

Posts 1–11 of 11 · Page 1 of 1
Question...
Hey guys,

How do I disable the X button in c++? I want to create a program that can't be closed out very easily. I'm currently learning c++ (not very far along...) and I'm using Dev C++.

Thanks,
If you are programming with Winapi, you can go to the part in the code where it says:
Code:
case WM_CLOSE:
PostQuitMessage(0);
return 0;
all you do is erase
PostQuitMessage(0);

when you do that the user will press the X but the program won't do anything.
Quote Originally Posted by 258456 View Post
If you are programming with Winapi, you can go to the part in the code where it says:
Code:
case WM_CLOSE:
PostQuitMessage(0);
return 0;
all you do is erase
PostQuitMessage(0);

when you do that the user will press the X but the program won't do anything.
I trolololed my mom like that :P
lol, ya it's fun. It's even more fun when you take out PostQuitMessage(0) and insert keylogger code plus hide the window, they think it's closed!(but we all know it's not). lol
fun stuff.
Quote Originally Posted by 258456 View Post
lol, ya it's fun. It's even more fun when you take out PostQuitMessage(0) and insert keylogger code plus hide the window, they think it's closed!(but we all know it's not). lol
fun stuff.
Well thats just Fing Mean
Quote Originally Posted by whit View Post


Well thats just Fing Mean
Yeah mang.

Y u guise all so cold hearted? D:
lol, another way to take the X out in winapi is to go to the part in the window code where it has the function CreateWindow and go to the 3rd parameter and erase WS_OVERLAPPEDWINDOW, this will take out the whole menu on top. That's also classic to watch. lol
No it was April fools day. National /me trolololololololololol family day. I did a crazy mouse once. That's funny as hell
Quote Originally Posted by fukojr2 View Post
No it was April fools day. National /me trolololololololololol family day. I did a crazy mouse once. That's funny as hell
Replace the cursor by a giant wobbly penis and hide the start button, so much more fun :P
Posts 1–11 of 11 · Page 1 of 1

Post a Reply

Tags for this Thread

None

Talk with us