My mistake, I forgot to post my code:
Code:
#include <iostream>
#include <iomanip>
#include <fstream>
#include <sstream>
#include <cmath>
#include <stdio.h>
#include <stdlib.h>
#include <string>
#include <vector>
using namespace std;
const char dictionary[14] = { 'a', 's', 'c', 'i', 'i', '_', 'd', 'i', 'c', 't', '.', 't', 'x', 't' };
ifstream dictInput;
vector <char> dictVect(0);
char n;
int main()
{
dictInput.open(dictionary);
if (dictInput.is_open())
{
while ( !ios::eof() )
{
if (!ios::eof())
{
n = dictInput.get();
cout << n;
dictVect.push_back(n);
}
else
// Do nothing
}
cout << endl;
}
return (0);
}
As it is right now, this can't compile. I'm getting error:
project.cpp(207) : error C2352: 'std::ios_base::eof' : illegal call of non-static member function
The filename is ascii_dict.txt, and it reads it well. My main problem is that I don't know how to get it to find end of file on ascii_dict.txt.