Drew Wutka
DWUTKA at Marlow.com
Fri Apr 15 15:11:48 CDT 2011
Boy John, you don't read anything I wrote. The entire point was about a difference between .Net and VB6/VBA. No point in explaining further, your soapbox is above the level I care to engage at. Drew -----Original Message----- From: accessd-bounces at databaseadvisors.com [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of jwcolby Sent: Friday, April 15, 2011 2:26 PM To: Access Developers discussion and problem solving Subject: Re: [AccessD] First real stumble with using VB.Net over VB So what you are saying (and I have no reason to disbelieve this) is that a public variable is a private variable wrapped in an invisible property call. If that is truly the case (and they are identical) then why does he see value / property differences? And everything that I said below stands. A variable (field when placed in a class) is a structure on the heap (apparently then wrapped in something to return the value to make it public), whereas a property is a keyword and a real function which can contain other stuff and does not contain any storage of it's own. I defy you to show me a variable running code to wipe your disk, but I can do so with a property. They are *not* the same thing. The fact that a public class variable "kinda sorta" emulates a private variable with a property wrapper does not make it a private variable with a real property returning the value. I truly don't give a rat's patuty if you or Drew wants to call a public variable a property. Apparently Drew desperately wants to do so - reason unknown. As I am not a VB6 person I have no vested interest either way, I am just pointing out the quite obvious problem with trying to apply the same name to two objects that perform quite differently and have quite different capabilities. I use properties and I often times have code in them which performs calculations or tests. I have never managed to do that with a variable of any kind. I have had properties which did not wrap a variable at all. A property (keyword / function) does not have any specific storage assigned to it unless you do so, intentionally, with more code. A variable ALWAYS has storage assigned on the stack / heap. Call both whatever you want, just please do not attempt to tell me that they are the same thing, they clearly are not. I will continue to call variables in a class a field and I will continue to call properties (keyword / function) a property. Everybody except Drew will understand me. John W. Colby www.ColbyConsulting.com The information contained in this transmission is intended only for the person or entity to which it is addressed and may contain II-VI Proprietary and/or II-VI Business Sensitive material. If you are not the intended recipient, please contact the sender immediately and destroy the material in its entirety, whether electronic or hard copy. You are notified that any review, retransmission, copying, disclosure, dissemination, or other use of, or taking of any action in reliance upon this information by persons or entities other than the intended recipient is prohibited.