file not defined

im using dev c++ and when i compile my code it gives me this message

31 main.cpp
File' undeclared (first use this function) 31 main.cpp (Each undeclared identifier is reported only once 31 main.cpp for each function it appears in.) 38 main.cpp implicit declaration of functionint fopen(…)’

and here is my code for it

File *File=NULL; // File Handle

if (!Filename)										// Make Sure A Filename Was Given
	return NULL;									// If Not Return NULL

File=fopen(Filename,"r");							// Check To See If The File Exists

if (File)											// Does The File Exist?
	fclose(File);									// Close The Handle
	return auxDIBImageLoad(Filename);				// Load The Bitmap And Return A Pointer

any help would be nice, thxs in advance

I believe File should be FILE

yea i had it that way, i guess i changed it before posting it, sorry, so file=FILE

try to #include <stdio.h> and also try this :stuck_out_tongue:

ok ur suggestion worked, but now its saying that glaux.h is missing? but if i compile other files it’ll work(other thatn the one im trying), is there anywhere i can download glaux and where would i put it, should i just try updating dev c++

checked up too see if glaux was still in file and it is, its in include/gl/glaux.h, so mabye a update is in order?

Hmmm of course you have to include both stdio.h and glaux.h.

I recommend a little more C/C++ practice before you start with OpenGL.

By the way, try to find what depends on glaux.h and replace it by something better, glaux dates from before stone age and is not maintained anymore.

replace it with what? like what would u sugggest?

Two words: GLU & GLUT
THe first is the utility library and the other is the utility toolkit. Also glut takes care of window initialization for you as well as other nice stuff. GLU should come with OpenGL I think, as for glut for windows go .