Wednesday, October 3, 2012

C# static methods in VB.NET

I was suprised by the lack of class (static) methods in VB.NET. Quick Google search pointed that class methods are called Shared in VB.NET:


Private Class BackupHistory
        Public BottomText() As String
        Public LastInserted, CurrentlyVisible As Integer

        Public Shared Sub Serialize(ByVal history As BackupHistory)
            '...
        End Sub
End Class

No comments:

Post a Comment