Q. Do you end your exception messages with a period?
From Best Practices for Exceptions† on MSDN in the section “Creating and raising exceptions”:
- Use grammatically correct error messages, including ending
punctuation. Each sentence in a description string of an exception
should end in a period. For example, “The log table has overflowed.”
would be an appropriate description string.
And regarding possible feedback to the user via the the application user interface, the question includes:
…Could also be an issue in localized resource strings.
The MSDN article referenced above also states:
- Include a localized description string in every exception. The error
message that the user sees is derived from the description string of
the exception that was thrown, and not from the exception class.
Also, from Exception.Message Property† at the beginning of the section “Remarks”:
Error messages target the developer who is handling the exception. The
text of the Message property should completely describe the error and,
when possible, should also explain how to correct the error. Top-level
exception handlers may display the message to end-users, so you should
ensure that it is grammatically correct and that each sentence of the
message ends with a period. Do not use question marks or exclamation
points. If your application uses localized exception messages, you
should ensure that they are accurately translated.
† .NET Framework 4.6 and 4.5