Visual Studio and SharpDevelop do not both set delegates to handle events in the same way. The way they are configured is slightly different. This makes it difficult to use VS in one place and #Dvelopment in another (in the same project).
For example, in VB Visual Studio does the following:
Private Sub OK_Button_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles OK_Button.Click Me.DialogResult = System.Windows.Forms.DialogResult.OK Me.Close() End Sub
AND...
Friend WithEvents OK_Button As System.Windows.Forms.Button
Thus, the control is declared not only with another area (this may also be a problem, but not the subject of this message), but with withevents. An event handler is then assigned to it by the position handles.
in #Develop, this is done like this:
Sub OK_ButtonClick(sender As Object, e As EventArgs) End Sub
and...
Private button1 As System.Windows.Forms.Button
Then in the InitializeComponent method
AddHandler Me.button1.Click, AddressOf Me.OK_ButtonClick
The most unpleasant thing about this, even if it is done in one way, another ideal will redo it, duplicate declarations and, of course, compile time errors.
Does anyone know of this, somehow configure default handlers? even if itβs just that they can be turned off, so can you just enter it manually?