does not account for a second cap. If anyone has a fix for this let me know.
<cfscript>
function CapFirst(str) {
var newstr = "";
var word = "";
var i = 1;
var strlen = listlen(str," ");
for(i=1;i lte strlen;i=i+1) {
word = ListGetAt(str,i," ");
newstr = newstr & UCase(Left(word,1));
if(len(word) gt 1) newstr = newstr &
LCase(Right(word,Len(word)-1));
if(i lt strlen) newstr = newstr & " ";
}
return newstr;
}
</cfscript>
Nancy
-----Original Message-----
From: stas [mailto:[EMAIL PROTECTED]
Sent: Tuesday, February 03, 2004 11:07 AM
To: SQL
Subject: Proper case function
Is there a function that will convert an all caps name to proper case?
Thanks
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]
