Title Case a string

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I read the following article:
http://support.microsoft.com/kb/312890/EN-US/

I need to convert the case of a text column in a DataTable object so I wrote
a method to do this however, the ToTitleCase method does not work if the case
is already in upper case.

I got around this by doing something like:
<code>
row[x] = textInfo.ToTitleCase(row[x].ToString().ToLower());
</code>

Is this normal behaviour? I've not found any doccumentation detailing this.
Surely the ToTiltleCase should do the same regardless of the original case
of the string?
 
This is good to know - I didn't know .NET had a way of getting title cased
strings. I wrote my own method for that. Thanks!
 
Back
Top