Thread: GetLength()

  1. #1
    Unregistered
    Guest

    Question GetLength()

    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?

  2. #2
    Mayor of Awesometown Govtcheez's Avatar
    Join Date
    Aug 2001
    Location
    MI
    Posts
    8,823
    To find the length of a string, use strlen.

  3. #3
    It's full of stars adrianxw's Avatar
    Join Date
    Aug 2001
    Posts
    4,829
    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.

  4. #4
    Registered User
    Join Date
    Feb 2002
    Posts
    7
    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()

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Code review
    By Elysia in forum C++ Programming
    Replies: 71
    Last Post: 05-13-2008, 09:42 PM
  2. OpenGL lighting problems
    By sirSolarius in forum Game Programming
    Replies: 0
    Last Post: 12-01-2003, 09:11 PM