Probs with MS VC++ 6.0

Hi, I’m using glutCreateWindow() for my main window, but sometimes the compiler just posts the quit message and the program terminates even though everything went right that far. Then if I press Shift+F5 instead of F5 it comes up with 14 illegal operations, but when I have closed all of them my program runs normally, even though it is really slow, and when I exit it, it throws another error, but that is minor…
The weird thing is, that this came up from nothing, I didn’t change the code, but suddenly he came up with this sh**. I had the same problem a few days ago, but it solved itself after the computer had a good night’s sleep.
What is the problem, how can I solve it, because it is very annoying to click through 14 errors every time and then have a program running dead slow.
thx for any replies

Try posting some of your code to see where you probably went wrong.

Well, here is my main function. The program executes normal until it is supposed to enter game mode.
glutInit(&argc, argv);
glutInitDisplayMode(GLUT_DOUBLE | GLUT_RGB | GLUT_DEPTH);
// setting the game mode replaces the above
// calls to set the window size and position.
glutGameModeString(“1024x768:16”);
// enter full screen
if (glutGameModeGet(GLUT_GAME_MODE_POSSIBLE))
glutEnterGameMode();
glutReshapeFunc(ChangeSize);
glutDisplayFunc(RenderScene);
glutKeyboardFunc(KeyboardFunc);
glutSpecialFunc(SpecialFunction);
// glutIdleFunc(RenderScene);
glutMotionFunc(MouseFunc);
glutTimerFunc(100, TimerFunction, 1);
SetupRC();

Originally posted by The stupid Beginner:
Well, here is my main function. The program executes normal until it is supposed to enter game mode.
glutInit(&argc, argv);
glutInitDisplayMode(GLUT_DOUBLE | GLUT_RGB | GLUT_DEPTH);
// setting the game mode replaces the above
// calls to set the window size and position.
glutGameModeString(“1024x768:16”);
// enter full screen
if (glutGameModeGet(GLUT_GAME_MODE_POSSIBLE))
glutEnterGameMode();
glutReshapeFunc(ChangeSize);
glutDisplayFunc(RenderScene);
glutKeyboardFunc(KeyboardFunc);
glutSpecialFunc(SpecialFunction);
// glutIdleFunc(RenderScene);
glutMotionFunc(MouseFunc);
glutTimerFunc(100, TimerFunction, 1);
SetupRC();

You need to enter your glutMainLoop();

Even if you dont enter your MainLoop, you should not get 16 errors…
What do the errors say?
Your code looked fine, the only thing that was missing was the loop…