All Tags »
.NET »
exception handling
Sorry, but there are no more tags available to filter with.
-
This is very bad!
try{ //do something that will throw an exception, like try to commit data to a database with malformed sql
} catch{ //sweep the dirt under the rug ;)
}
Consequences/Results - Your boss will not see any exceptions or code crashes, but it might come back to bite you in the butt when ...
-
In certain conditions, we should not be using exceptions. For example, Try Catch blocks can be avoided in certain cases. If you have some .NET 1.0 code, you might not be taking advantage of .NET 2.0 new TryParse functions, which avoid exception handling and are much faster.
For example:try
{
...