GetLength
Return the number of bytes (or number of characters) in this string object. The count does not include a null terminator.
int GetLength( )
An integer value equal to the length (number of bytes minus the null character) of this string.
EX1
void string_GetLength_ex1() { string str( "cow" ); int nRet = str.GetLength(); out_int("", nRet);//3 str.Empty(); nRet = str.GetLength(); out_int("", nRet);//0 }
origin.h