Derivation and Inheritance

jfackler

Junior Contributor
Joined
Mar 15, 2003
Messages
393
Location
Cincinnati, Ohio
Visual Basic:
Class Mom
    Public FirstName As String
    Public LastName As String

Sub New (ByVal FirstName As String, ByVal LastName As String)
    Me.FirstName = FirstName
    Me.LastName = LastName
End Sub
End Class

Class Son
     Inherits Mom

  Public Name

  Public Sub New (ByVal FirstName As String, ByVal LastName As String)

   MyBase.New (FirstName, LastName)

  Me.Name = "Son of " & FirstName & " " & LastName

End Sub
End Class


It's Mothers Day here in the States, a national holiday for obstetricians, of which I am one.

Call your mother.

Jon
 
Last edited:
Back
Top