Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Identifier Not Found Error 2

Status
Not open for further replies.

jamez05

Programmer
Jul 29, 2005
130
US
I'm trying to compile a simple console program on Windows that uses the strLen() function. However, when I try
to run it I get the following error:
Code:
 error C3861: 'strlen': identifier not found

Here's my code, not sure what I'm doing wrong:

Code:
#include <stdio.h>
#include <string.h>
#include "stdafx.h"


int _tmain(int argc, _TCHAR* argv[])
{
	int i;
	int correctParams = 1;
	int length;
	char *arg1;

	if ( argc != 3 ) {
		printf( "Enter a Smiles string and fragment your searching for\n" );     
		correctParams = 0;
	}
	if (correctParams == 1) {

		length=strlen(argv[1]);

	}

	return 0;
}
 
Code:
#include "stdafx.h"
This line should always be the first file to be #included if you are using pre-compiled headers.

Try selecting: Build->Rebuild All
 
Or turn off pre-compiled headers until you have a project which is both large enough and stable enough to make effective use of pre-compiled headers.

--
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top