ChoosePixelFormat shuts down app

Hey there,

I am at a complete loss. The first time I run my application it runs fine.
Every time after that, as soon as it hits ChoosePixelFormat, it shuts down the application. The only way i can get it to work is to restart the computer.

I have windows 98, using borland builder, nvidia 32 meg geforce DDR (44.30 detonator drivers)…1 ghz amd with 512 megs ram.

The same app works just great on windows 2000
please, any suggestions would be awesome.

Jeremy

[This message has been edited by bumby (edited 08-07-2003).]

Suggestion: post the code where the crash occurs.

Are you calling:

wglMakeCurrent(NULL,NULL);
wglDeleteContext(HGLRC);

at exit?

Thanks,

that did the trick!

glad to be of service

It actually turned out to be a 2 part problem.

I hadnt destroyed the rendering context, but there was also a bug in the nvidia driver ( i have 44.03). It wasnt shutting down DDHelp properly. I cant remember exactly what the error message was but it was something about DDHelp exception in module …

I have no idea why DDHelp was needed, but i installed an old driver 30.82 and everything worked properly.

hope this may help anyone else.

Jeremy

well not quite perfectly, i actually had to re install directx 8 too.