Ok so I have a simple program that reads in numbers from a file and counts the amount of even and odd numbers in the file and prints out the results, but when I try to compile I get the error C2248 and when i try to find the error it brings me to another page, so is my error not even part of my code and it is something else. Any help would be great

Code:
#include <iostream>		// For cin / cout
#include <string>		// For file name
#include <iomanip>		// For setw
#include <fstream>		// For file input
using namespace std;

void IsEven(ifstream din);

int main ()
{  
	string fileName;

	cout << "Please enter a file name "<<endl;
	cin >> fileName;

	ifstream data;

	data.open(fileName.c_str());

	if(!data)
	{
		cout << "No such file found!" << endl;
	}
	else
	{
		IsEven(data);
	}
    return 0;
}

void IsEven(ifstream din)
{
	/*
		Purpose: Takes input from a file and determines how many even numbers and odd numbers are in the file

		Pre:	 File

		Post:	 How many even numbers are in the file and how many odd numbers are in the file
	*/
	int num;
	int even = 0;
	int odd = 0;
	din >> num;
	while(din)
	{
		if(num % 2 == 0)
			even = even ++;
		else
			odd = odd ++;
		din >> num;
	}

	cout << "There are " << even << " numbers in the file and " << odd << " numbers in the file." << endl;

}


this is my error message

1>c:\program files\microsoft visual studio 8\vc\include\fstream(675) : error C2248: 'std::basic_ios<_Elem,_Traits>::basic_ios' : cannot access private member declared in class 'std::basic_ios<_Elem,_Traits>'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 8\vc\include\ios(151) : see declaration of 'std::basic_ios<_Elem,_Traits>::basic_ios'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> This diagnostic occurred in the compiler generated function 'std::basic_ifstream<_Elem,_Traits>::basic_ifstream(const std::basic_ifstream<_Elem,_Traits> &)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]