• Saves Valuable Time
  • Trusted Accuracy for 12 Years
  • 15-Day Money-Back Guarantee

C# Equivalent to VB Constructors & Finalizers

VB.NET C#
Class Foo
    Public Sub New()
        Me.New(0) 'call to other constructor
    End Sub

    Public Sub New(ByVal i As Integer)
    End Sub

    Protected Overrides Sub Finalize()
    End Sub
End Class
class Foo
{
    public Foo() : this(0) //call to other constructor
    {
    }

    public Foo(int i)
    {
    }

    ~Foo()
    {
    }
}


Use Instant C# to convert from VB.NET to C#.     

Additional resource: VB.NET and C# Equivalents


Copyright © 1997 – 2017 Tangible Software Solutions Inc.