So using the system command file we can use file to determine if a file is ASCII Text or "data". I wanted to know if there is a way to check in code which one it was? I want to basically throw a corrupt error if the file is 'data'. I am using ifstream for reading the files. Thanks for any help!
Duplicate of this question.