Program Closing

Hello!
My question is how to make program can't be exited. I want to make program who can close only with typing correct word. I work in Code Blocks. Anyone know?
That's an OS-dependent thing to do. On Windows, you need to process the WM_CLOSE message (sent to your application's window) or the WM_QUIT message (sent to the application's message loop).

I don't recall the X events off the top of my head.

A lot of GUI frameworks abstract this for you.

For a console application, you cannot stop the user from closing the window. (And the message to hook a console window close does not work on certain versions of windows -- as a known bug.)

If you could provide more information, we might be able to give a more specific answer.
I want to make program when will be pressed exit buton don't will be closed or when is pressed exit button who will auto startup for about 5 minutes
This is a bit suspicious. Preventing a user from closing a program sounds like malware.
No, program will be closed when user type correct world
Topic archived. No new replies allowed.