what is a delegate? what it is used for?
Answer Posted / subbu
Delegates are a type that references method. Normally when
we calling a method we will pass some data to that method
as input parameter. But in some scenario we might need to
pass method as input parameter to other method in such case
we can use delegate.
Delegate wraps any method which matches its signature,
calling a delegate result in calling a method so this gives
the ability to call the method programmatically based on
our business needs.
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
How to add controls dynamically to the form using c#.net.
Why are strings immutable in c#?
What are fields in c#?
What is a Managed Code??
Can an abstract class have a constructor c#?
What do u mean by delegation of authority?
What is function and method in c#?
Can we override constructor in c#?
What is an abstract class c#?
What are the main reasons to use c# language?
Can structs in c# have destructors?
Is there regular expression (regex) support available to c# developers?
Can we use "this" command within a static method?
What is literal in c#?
Can fields inside a class be virtual?