🔒 Locked
Strings... lowercase
Advertisement
Original Post
int tolower( int c );
This converts a character to lowercase. It''s in stdlib.h.
-Ironblayde
Aeon Software
The following sentence is true.
The preceding sentence is false.
This converts a character to lowercase. It''s in stdlib.h.
-Ironblayde
Aeon Software
The following sentence is true.
The preceding sentence is false.
Just use _strlwr ... it converts a full string to lowercase.
Syntax is :
_strlwr(LPSTR szString);
where szString is your string you want to convert.
... so why don't you come here ? You realy should come.
http:\\zordan.gnw.de
Syntax is :
_strlwr(LPSTR szString);
where szString is your string you want to convert.
... so why don't you come here ? You realy should come.http:\\zordan.gnw.de
_strlwr will only work in VC++, and you are probably learning ANSI C++, so you don''t want to do that in your class. Otherwise, you''ll be learning something that will not work sometimes.
Use tolower; you can make your own function to convert a whole string.
"Whoever performs only his duty is not doing his duty." --Bahya ibn Pakuda
Use tolower; you can make your own function to convert a whole string.
"Whoever performs only his duty is not doing his duty." --Bahya ibn Pakuda
If you''re leeb then you can use lcase$()
---------------------------
Tell your friends. Tell your family. Tell your...don't tell your family. The GDTalker
---------------------------
Tell your friends. Tell your family. Tell your...don't tell your family. The GDTalker
_strlwr(char* string);
is defined in string.h and
is definitly not only part of vc++ but
part of the Ansi C specs.
... so why don't you come here ? You realy should come.
http:\\zordan.gnw.de
is defined in string.h and
is definitly not only part of vc++ but
part of the Ansi C specs.
... so why don't you come here ? You realy should come.http:\\zordan.gnw.de
I can't find the _strlwr() function in my books or online docs either. Functions starting with an underscore are _usually_ compiler-specific. I'd also like to know where you've found out that _strlwr() is part of the ANSI C standard 
Edited by - Muzzafarath on October 30, 2000 11:19:14 AM
Edited by - Muzzafarath on October 30, 2000 11:19:14 AM
Upon inspection of _both_ the C, C89 and C99 ANSI/ISO standards, that function does not exist. Therefore, I conclude it is not part of any ANSI/ISO standard.
Please state the nature of the debugging emergency.
Please state the nature of the debugging emergency.
Dang you are right ... this text fragment is taken from the
DJGPP C Library Reference :
strlwr
Syntax
#include
char *strlwr(char *string);
Description
This function replaces all upper case letters in string with lower case letters.
Return Value
The string.
Portability
not ANSI, not POSIX
Example
char buf[100] = "Hello";
strlwr(buf);
So I hope you take my excuse
P.S. The function is available for most (I don''t know any whitout) compilers anyway >:>
... so why don't you come here ? You realy should come.
http:\\zordan.gnw.de
DJGPP C Library Reference :
strlwr
Syntax
#include
char *strlwr(char *string);
Description
This function replaces all upper case letters in string with lower case letters.
Return Value
The string.
Portability
not ANSI, not POSIX
Example
char buf[100] = "Hello";
strlwr(buf);
So I hope you take my excuse
P.S. The function is available for most (I don''t know any whitout) compilers anyway >:>
... so why don't you come here ? You realy should come.http:\\zordan.gnw.de
Topic Locked
This topic has been locked by a moderator. New replies are not allowed.
Sign in to reply to this topic.
Advertisement