V

To complete this example, update the generated SportsCar class with a public method named PrintPetName() as follows (don't concern yourself with the syntax at this point; you'll dig into the details of class design beginning in the next chapter):

Public Class SportsCar Inherits Car

Public Function PrintPetName() As String petName = "Fred"

Return String.Format("Name of this car is: {0}", petName) End Sub End Class

Was this article helpful?

0 0

Post a comment