J
jakk
Hello All,
I have a question about how to handle exceptions. Iam working on an
ASP.NET application which has a presentation layer, Business Layer and
DataAccess Layer. Iam confused about where to handle exceptions. Say
forexample I have a requirement where certain value has to be between
30-72 only and Iam doing this validation in the the BL. if the value is
not between 30-72 then Iam throwing an exception back to the UI layer.
Is this the right way to do or should I just check for the value and
use some variable or something to inform UI layer about the invalid
value.
Since it is a business requirement i thought of throwing an business
exception. Basically Iam confused to differentiate between a business
exception and a normal validation. what kind of exceptions should be
tried and caught and thrown in the Business Layer? Can someone please
help me solve this confusion?
Thanks
Jack
I have a question about how to handle exceptions. Iam working on an
ASP.NET application which has a presentation layer, Business Layer and
DataAccess Layer. Iam confused about where to handle exceptions. Say
forexample I have a requirement where certain value has to be between
30-72 only and Iam doing this validation in the the BL. if the value is
not between 30-72 then Iam throwing an exception back to the UI layer.
Is this the right way to do or should I just check for the value and
use some variable or something to inform UI layer about the invalid
value.
Since it is a business requirement i thought of throwing an business
exception. Basically Iam confused to differentiate between a business
exception and a normal validation. what kind of exceptions should be
tried and caught and thrown in the Business Layer? Can someone please
help me solve this confusion?
Thanks
Jack