- Follow via:
- RSS
- Email Alert
Question
0
Votes
VB6: How to create new properties to the forms????
How to create new properties to the form apart from existing properties in its properties box????
Tags:
off-topic
21st May 2012
Answers (1)
0
Votes
What do you mean, new propertise?
Are you talking about get and let?
What new property do you want to add?
'Return primitive, Variant can be changed to any primitive data type
Public Property Get PropertyName() As Variant
PropertyName = LocalVariable
End Property
Public Property Let PropertyName(ByVal vNewValue As Variant)
LocalVariable = vNewValue
End Property
'return object, key difference is the "set" keyword.
Private Property Get ObjectName() As Object
Set ObjectName = LocalObjectVariable
End Property
Private Property Let ObjectName(ByVal vNewValue As Object)
Set LocalObjectVariable = vNewValue
End Property
What new property do you want to add?
'Return primitive, Variant can be changed to any primitive data type
Public Property Get PropertyName() As Variant
PropertyName = LocalVariable
End Property
Public Property Let PropertyName(ByVal vNewValue As Variant)
LocalVariable = vNewValue
End Property
'return object, key difference is the "set" keyword.
Private Property Get ObjectName() As Object
Set ObjectName = LocalObjectVariable
End Property
Private Property Let ObjectName(ByVal vNewValue As Object)
Set LocalObjectVariable = vNewValue
End Property
Updated - 22nd May 2012

































