vchapran
May 10th, 2001, 11:31 AM
In an existing application in a standard module there are several Public Property Get. Who can explain me, why there were used instead of Public Functions. There are no local members at all. Those properties are used as regular functions. Is there any advantage with this approach? Or it's just bad knowledge of VB?
Thank you.
Vlad
Johnny101
May 10th, 2001, 01:27 PM
Functionaly, they are the same thing - do some action, return a result. Design-wise, a Get property procedure should return only the current value of some local variable in a class module. If the routine is to perform some sort of action(s), then it should be a function, so everyone knows, just by looking in the object browser, what its purpose is.
just my $.02
john
John Pirkey
MCSD
http://www.ShallowWaterSystems.com
http://www.stlvbug.org