Re: [2005] Class Inheritance
At a glance...
When you declare myVan you aren't passing in a maximum speed unlike when you declare myCar, so it is defaulting max speed to zero.
Re: [2005] Class Inheritance
If you had used the debugger you'd have seen exactly what keystone_paul said. If you'd placed a breakpoint on the Set method of the Speed property you'd have seen that execution enters the If block, because CurrSpeed is greater than MaxSpeed, and sets CurrSpeed to the value of MaxSpeed, which is zero.
The debugger exists so you can debug your code, so you should make use of it. The first tools you need to use are breakpoints (F9), which halt execution at a specific line of code, and then Step Over (F10) and Step Into (F11), which let you step through your code one line at a time. At each step you can mouse over variables and properties to determine their value, use the Autos, Locals, Watch and Immediate windows to evaluate variables, properties, methods and expressions and use the Command window to execute code.