Property Overrides

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Jimmy V

    #1

    Property Overrides

    I want to override a property in VB, I know in C# I can do this:

    Public new String Text
    {

  • Alex Meleta

    #2
    Re: Property Overrides

    Hi Jimmy,

    ....
    Class Base
    Public Overridable ReadOnly Property Total() As Double
    Get
    Return ....
    End Get
    End Property
    End Class

    Class Base
    Inherits Derived
    Public Overrides ReadOnly Property Total() As Double
    Get
    Return ...
    End Get
    End Property
    End Class
    ....
    There is the full example: http://www.awprofessional.com/articl...&seqNum=4&rl=1

    PS. "new" statement is not an overriding. It's hidding.

    Regards, Alex
    [TechBlog] http://devkids.blogspot.com


    JVI want to override a property in VB, I know in C# I can do this:
    JV>
    JVPublic new String Text
    JV{



    Comment

    Working...