/Home /Archive /Syndicate /Blog /Support /About /Contact  
All Visual Basic Feeds in one place!





Relaxed delegate conversion, introduced in Visual Basic 2008, enables you to assign subs and functions to delegates or handlers even when the signatures are not identical. Therefore, binding to delegates becomes consistent with the binding already allowed in method invocations. 

In Visual Basic prior to 2008:

Sub OnClick(ByVal sender As Object, ByVal e As EventArgs) Handles RunButton.Click
    MessageBox.Show("Visual Basic prior to VB 2008")
End Sub

In Visual Basic 2008 (VB9)

Sub OnClick() Handles RunButton.Click
    MessageBox.Show("Look Mom, no parameters!")
End Sub

Details:  Relaxed Delegate Conversion

Mike McIntyre
www.getdotnetcode.com

 

© 2005 Serge Baranovsky. All rights reserved.
All feed content is property of original publisher. Designated trademarks and brands are the property of their respective owners.

This site is maintained by SubMain(), a division of vbCity.com, LLC