Resource strings/identifiers should be spelled correctly (CA1703/CA1704, Microsoft.Naming)

by Mark Zhou 18. October 2010 19:43

This rule simply checks the spelling of the resource strings/identifiers by tokenizing compound words. By default, Code Analysis tool or FxCop uses the English spell checker, any tern of an identifier or resource string is considered English, hence, if any violation happens, this rule will hit and show as a warning.

There are many words for the people to spell incorrectly; for example, “definitely” is a word which cause 70% of the people in UK misspell. In addition, some words, like “occurrence”, “ninth”, and so on, are also very likely to misspell (people may not double “r” for “occurrence”, add an “e” before the “t” for “ninth”, etc).

Therefore, do not suppress this rule in all the cases, this enhances the readability of your software libraries. In a very rare circumstance, if you come with new word such as “googled”, or “Lync” (a unified communication server name of the newly released Microsoft platform that formerly called Microsoft Communication Server), you can add the word into the code analysis dictionary as I discussed in the last article, Resource string/identifier compound words should be cased correctly (CA1701/CA1702).

For more information, see this MSDN link for CA1703.

Tags: , , ,

Pingbacks and trackbacks (1)+

Add comment




  Country flag
biuquote
  • Comment
  • Preview
Loading


Translate This Page

About Mark

Mark is a developer who works for building base class libraries and tools for developers.

Mark's Awards

Microsoft Community Contributor

Month List

Who visit this site

Recent Comments

Comment RSS