Click here to Skip to main content
15,888,039 members
Please Sign up or sign in to vote.
4.00/5 (1 vote)
See more:
I have two projects Project1 and Project2. I have refernce of Project2 in Project1.
I have declared a Delegate in Project2 and on click of button I am invoking the Delegate.
Project2 - Form2 Code :
VB
Public Delegate Sub ExternalDelegate()
Public Class Form2
    Public Event Del As ExternalDelegate

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
        RaiseEvent Del()
    End Sub
End Class

In my project1 I have form1 where I have to register to the event present in Form2 of project2.

So can anyone tell me how to call a method present in Form1 from form2.

Let me know if my question is not clear .
Posted
Updated 2-May-12 22:18pm
v2
Comments
Sergey Alexandrovich Kryukov 4-May-12 17:20pm    
Yes, the role of ExternalDelegate is not clear. By they way, its signature does not fit the recommended event usage.
Better explain what do you want to achieve from the standpoint of the application and the ultimate goal of it.
--SA

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900