I have a class that was written in
VB.Net that I need to call in C#. This isn't the problem. The problem is that I have a delegate like so:
Code:
#Region "DELEGATES"
Public onCURRENT_STATUS As CURRENT_STATUS
Public Delegate Sub CURRENT_STATUS(ByVal strMessage As String, ByVal CLS As clsLD_HISTORY)
#End Region
Then I have a sub that calls the onCURRENT_STATUS like so
Code:
public sub TEST_DELEGATE
'SEND MESSAGE - STARTING
If Not Me.onCURRENT_STATUS Is Nothing Then
Me.onCURRENT_STATUS.Invoke("Starting Process...", Me)
End If
end sub
In
VB.Net I would call it like so :
Code:
dim myCLASS as new TEST_CLASS()
Me.myCLASS.onCURRENT_STATUS = AddressOf Me.DISPLAY_STATUS
Where Me.DISPLAY_STATUS is a sub or function in the calling class that matches the original delegates signature.
In C# I can't figure out how to do the AddressOf? Is it possible?
Please need help ASAP.
Thank you,
Christopher P. Cooper
It's important for us to explain to our nation that life is important. It's not only life of babies, but it's life of children living in, you know, the dark dungeons of the Internet."â George W. Bush - Arlington Heights, Ill., Oct. 24, 2000