This may be a stupid question to most...but I have not been able to figure it out. I'm writing a dll in c++. I want to read from a file, so I do what I have always done:
#include <fstream.h>
...some code...
//inside a function
ifstream fin;
fin.open("myfile.txt");
string temp;
fin>>temp;
cout<<temp;
everything runs just fine, but nothing is printed to the screen. I have stepped through the code and when temp is read in, "" is what appears in temp. It's almost as if nothing is held in my file. The .txt file is in the same directory as the program calling the dll. Hope this can be a simple answer...thanks in advance.
T-Hawk