Benj Nunez
unread,May 28, 2009, 9:46:45 PM5/28/09Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to DotNetDevelopment, VB.NET, C# .NET, ADO.NET, ASP.NET, XML, XML Web Services,.NET Remoting
I think you need to cast the Exception "ex" parameter.
Evaluate what the "ex" parameter holds and that would mean
declaring/anticipating what particular Exceptions might be thrown to
it like:
public void HandleException(Exception ex)
{
if ( (ex as MissingDependencyException ) != null) //
MissingDependencyException raised?
{
...do
stuff... // ..
then handle it...
}
if ( (ex as DividebyzeroException ) != null) //
DivideByZeroException raised?
{
...do different
stuff... // then handle
like...
}
// other possible exceptions define them here...
}
Regards,
Benj