What is the significance of delegates. Where should they be used? what are the situations where we require them?

Questions by mkatpatal   answers by mkatpatal

Showing Answers 1 - 3 of 3 Answers

kaushik banerjee

  • Aug 24th, 2007
 

Delegates are used as pointer to hold the controls actually i used the delegates when there is problem in VB.Net 2005 where each control is already threaded, to use my personla thread on these control i used delegates
Ex:
Private Delegate Sub dd()

Dim d1 As New dd(AddressOf c1)
Dim t1 As New Threading.Thread(AddressOf thread1)


public sub Thread1()
r1 =

Me.Label1.BeginInvoke(d1)

Me.Label1.EndInvoke(r1)
end sub

Public Sub c1()

Me.Label1.Text = ct1

Me.Label1.Refresh()

End Sub

  Was this answer useful?  Yes

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

 

Related Answered Questions

 

Related Open Questions