Need help with error LNK2019: unresolved external symbol _main referenced in function ___tmainCRTStartup

I am getting this error when I try to run my program:
1>MSVCRTD.lib(crtexe.obj) : error LNK2019: unresolved external symbol _main referenced in function ___tmainCRTStartup
Here is my program:
1
2
3
4
5
6
7
8
9
10
#include "stdafx.h"
#include <iostream>

using namespace std;

int main()
{
	cout << "Hello.";
	return 0;
}

Any help is appreciated!
try changing line 6 from int main() to int _main()
Topic archived. No new replies allowed.