I need to know how to use the GetLength function so that I can find the length of a string. Can anyone help me out, if this is even possible?
This is a discussion on GetLength() within the C++ Programming forums, part of the General Programming Boards category; I need to know how to use the GetLength function so that I can find the length of a string. ...
I need to know how to use the GetLength function so that I can find the length of a string. Can anyone help me out, if this is even possible?
To find the length of a string, use strlen.
-Govtcheez
govtcheez03@hotmail.com
Or the .size() member function if you are using the string class.
Wave upon wave of demented avengers march cheerfully out of obscurity unto the dream.
if you code in VC++, use the _tcslen(), _tcs is basically a substitute, when compiled in ANSI, it gets translated to strlen(), if compiled in unicode, it gets translated to wstrlen()