February 3, 2009 at 11:59 am
Hello All,
I am using ProperCase(FirstName) and ProperCase(LastName) for saving the first and last names in our C# Web application.
But for some names like "MacDonald" it is saving as "Macdonald".
How can I resolve this issue?
Please help.
Thank you,
Regards,
CK
February 3, 2009 at 12:22 pm
the best way is to update from a list of known last names...you cannot assume that every last name that starts with mac... gets it's 4th letter capitalized...
macaroni, machiavelli are just two lame examples.
compile a table of Family Last Names, and update from that.
maybe you can get away with it for Mc, McClintock or whatever, and the same for O'Brian...everything after a single quote, as long as it's for a FamilyName
Lowell
February 4, 2009 at 6:33 am
I worked for a company that did a lot of mass marketing and one thing the owner was completely against was trying to proper case legacy name information (and I completely agree with him).
You cannot come up with an algorithm that will work - because there are simply no rules. MacDonald and Macdonald are both correct - for different people. Dutch names get pretty bad - the Van can "sometimes" be capitalized.
People can be pretty sensitive about their names. Trying to programmatically fix name casing is a failing endeavor.
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply