Is there a way to get the windows.h file on a mac? or is there an identical file for mac? if you know the answer please help or know some way to do what I am trying to... or just any info please help.... thanks
Is there a way to get the windows.h file on a mac? or is there an identical file for mac? if you know the answer please help or know some way to do what I am trying to... or just any info please help.... thanks
Um, no. Mac and Windows are two very different operating systems. windows.h is for Windows programming, not Mac or any other *nix OS. I assume you're trying to get a program running on Mac OS X that uses the Win32 API?
no I am not very like good at C I can do a lot of simple programming, but I just want to use some of the functions included with it.. such as the sleep function..
Then use sleep() from unistd.h
It's in seconds, whereas Win32 Sleep() is in milliseconds.
well what if I want to use other functions in windows.h do I just have to find out where they are. And is there is big database type thing for that unistd.h, like there is for msdn... like for all basic mas/ Unix headers?
Yes.
well... what is it lol and why is ur font red?
that was a good hint
Lol
Hmm...what's the function for linux-ubuntu?
sleep() is the Linux/Unix function. The function in Windows is Sleep().
If you want a shorter sleep time than a second, use "usleep()" in Linux, it takes a time in microseconds. There's also a nanosleep, but that's essentially teh same as usleep internally, and just 3 digits longer number, but no better actual precision - if your process goes to sleep, it will sleep for more than a few nanoseconds, that's guaranteed.
--
Mats
Compilers can produce warnings - make the compiler programmers happy: Use them!
Please don't PM me for help - and no, I don't do help over instant messengers.
Sweet, thanks!
well I couldn't get the windows.h header file so that was why I was asking..