Buenas!
¿ Saben que una misma propiedad puede tener hasta tres nombres sinónimos ?. (identificadores)
Clase
Código:
Property text, document, paper As String
Private htext As String
Private Function text_Read() As String
Return htext
End
Private Sub text_Write(Value As String)
htext = Value
End
Main:
Código:
Public Sub Main()
Dim testThing As New Thing
testThing.text = "Hello World!"
Print testThing.text
Print testThing.document
Print testThing.paper
End
Salida:
Cita:
Hello World!
Hello World!
Hello World!
Cita:Property Synonymous
PROPERTY [ READ | WRITE ] Identifier [ , Synonymous1 [ , Synonymous2 ... ] ] AS Datatype
SINCE 3.1
It is possible to declare up to three synonymous to the declared properties by using the second syntax.
Saludos