1.基本使用
' 长方体的类Cuboid Private are Private hig Property Get area() area = are End Property Property Get high() high = hig End Property Function volume() volume = area * high End Function Function init(area, high) are = area hig = high End Function
基本使用
Public Sub classt() Dim cuboid As New cuboid Call cuboid.init(2, 4) MsgBox cuboid.volume End Sub
2 .