Let Property

shamas21

Registered User.
Local time
Today, 20:50
Joined
May 27, 2008
Messages
162
Hi All

Is there any point in creating a Let Property in a class without having the Get Property to go with it?

For example

Code:
Private sConnectTo As String

Public Property Let ConnectTo(ByVal Value As String)
    sConnectTo = Value
End Property

Code:
Sub GetDataFromSQLServer()

    Dim GetAccessData As New GetData
    
    GetAccessData.ConnectTo = "Access"
    
End Sub

So the above code would allow the user to set the property to something but it becomes useless without passing the value back right? Or maybe there is advantages for have Get or Let by themselves?

Thanks
 

Users who are viewing this thread

Back
Top Bottom