I am writing a small app that checks for the existence of some files. The problem is that when I create the stream, and associate a file with the stream, the fille will be created if it didnt exist. I did some reading and it said to use ios::nocreate on the open() function. Here is a code snippet below:
//#include <ios> //I even tried include this to help
fin.open("student.tab", ios::in | ios::nocreate);
When I compile this code with the ios::nocreate in it, it generates error messages saying that nocreate is not a member of 'basic_ios<char,struct std::char_traits<char> >', but yet the documentation says to do it that way. What am I doing worng?