I use MS MS Visual C++ and save with the extension .c when I program in C...I want to use the exit() function and MS Visual C++ wont understand my #include <stdlib.h>...WTF!!!
I use MS MS Visual C++ and save with the extension .c when I program in C...I want to use the exit() function and MS Visual C++ wont understand my #include <stdlib.h>...WTF!!!
Care to post the code? I'll try it in my MS Visual C.
Mike
NEVER PET YOUR DOG WHILE IT'S ON FIRE!
Check to see if the file stdlib.h is really there in the 'include' folder. And check for a probable typo in your code where you are including this file name.
i checked for typos and used an exit(1);
the code was
#include <stdio.h>
#include <stdlib.h>
main()
{
//rest of code goes here
exit(1);
return 0;
}
AND IT DIDNT WORK
the rest of the code is length but my errors came from the stdlib.h
and it said exit was not a function...because of the stdlib.h not being valid
So, what errors do you get if you compile something simple like this (paste them here):
Code:#include <stdio.h> #include <stdlib.h> int main(void) { exit (1); return 0; }
When all else fails, read the instructions.
If you're posting code, use code tags: [code] /* insert code here */ [/code]
well well
i recompiled my old program and it worked!!!
guess it was an OS error...i am using windows after all...