what is a delegate? what it is used for?
Answer Posted / ganesh
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.
hgfhfghbgf
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
Any problem found in vs.et
Can we have two main methods in c#?
Difference between value and reference type. What are value types and reference types?
How do I create a delegate/multicastdelegate?
What is the difference between a function and a method?
What is the relation between classes and objects?
What is the base class for array types?
Is c# a technology?
How do destructors and garbage collection work in c#?
What is the difference between string and stringbuilder in c#?
Is it true that all c# types derive from a common base class?
Can you inherit multiple abstract classes in c#?
How Reflection is used and what it's significance ?
What is hierarchical inheritance in c#?
How to use delegates with events?