Explain about throw keyword?
Answer Posted / tiger kumar
yes,its used to throw the user defined exception.
But its not always good habit to use throw exception.
Some times we can predict it will throw the exception.If we
know the error will come there in the earlier means why we
need to use the exceptions.we can solve it while writtting
code itself.
| Is This Answer Correct ? | 11 Yes | 4 No |
Post New Answer View All Answers
What is Satellite Assemblies ?
What is a class in unity?
How can you prevent escaping on backslashes in C# with string definitions?
Are c# generics the same as c++ templates?
What are extension methods and where can we use them?
What is a partial class. Give an example?
What's the implicit name of the parameter that gets passed into the set method/property of a class?
What happens if a static constructor throws an exception?
What does convert toint32 mean?
What is satellite assembly? And steps to create satellite assembly?
What do you mean by default constructor?
4. Describe the process when we send a request URL? And who is responsible for that?
What is the difference between struct and class c#?
Can we create instance of private class in c#?
Can we make a Static Constructor Parameterized? Give Reason with your answer