Hello
In case if theres any system exception, which should i use?
System.Exception or System.SystemException
Thanks,
Hnasen
Hello
In case if theres any system exception, which should i use?
System.Exception or System.SystemException
Thanks,
Hnasen
Hi @hansen_Lobo
I think both will give you the same exception descripton
System exception - exception occurred due to system ( web application, stand alone application etc.) Eg: application not reachable , Ui element not found etc
Mostly we use system.exception
System.Exception
is the base class for all exceptions in the .NET Framework.System.Exception
to capture any exception thrown in your code. However, it’s considered a best practice to catch more specific exception types whenever possible, as it allows for more targeted error handling.System.SystemException
is a base class for system-level exceptions in the .NET Framework.System.Exception
and represents exceptions that are thrown by the common language runtime (CLR) or other system-related issues.System.SystemException
include NullReferenceException
, IndexOutOfRangeException
, and InvalidOperationException
.This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.