lstrlen Function--------------------------------------------------------------------------------The lstrlen function returns the length in bytes (ANSI version) or WCHAR values (Unicode version) of the specified string (not including the terminating null character).
http://community.csdn.net/Expert/FAQ/FAQ_Index.asp?id=83989
http://community.csdn.net/Expert/FAQ/FAQ_Index.asp?id=192415
{
ASSERT(s != NULL);
int iLen = strlen(s) + 1;
WCHAR *ws = NULL;
int iNeed = MultiByteToWideChar(CP_ACP, 0, s, iLen, ws, 0);
ws = new WCHAR[iNeed + 1];
MultiByteToWideChar(CP_ACP, 0, s, iLen, ws, iNeed);
iLen = wcslen(ws);
delete[]ws;
return iLen;
}上面的函数就可以了!
size_t _mbslen( const unsigned char *string );