| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
string problems
I'm trying to covert a string to all lowercase using
tolower(text); but when i try and compile it I get two errors. 1. invlaid conversion from 'char*' to 'int' 2. initializing argument 1 of 'int tolower(int)' can someone suggest a fix? thanks |
|
#2
|
|||
|
|||
|
The function tolower expects a character (which is also an int in c) not a character string. You will need to iterate through the character string passing each character into the tolower function and using what is returned to build a new string which will be all lower case.
-KM- |
![]() |
| Viewing: Dev Articles Community Forums > Programming > C/C++ Help > string problems |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|