Charlotte Foust
cfoust at infostatsystems.com
Fri Jun 9 16:19:00 CDT 2006
This is a simplified class, Lambert. In fact, any public variable in a class is a property of the class. You just can't control the usage of that property. I'm sure Drew will get to the "proper" approach later. ;o} Charlotte -----Original Message----- From: accessd-bounces at databaseadvisors.com [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Heenan, Lambert Sent: Friday, June 09, 2006 2:01 PM To: 'Access Developers discussion and problem solving' Subject: Re: [AccessD] Basic Unbound Form with Classes and Collections Par t1. <snip> Our table has three fields, so we'll create three easy properties, and a fourth which will be derived. So, in the code page type the following under the 'Option Compare Database' line: Public ID As Long Public FirstName As String Public LastName As String [ These are not properties at all, they are class member fields, and making them public is a Q&D solution which defeats the purpose of data encapsulation that classes offer. A real property Get and Set pair would correct this, with the member fields being change to Private] Lambert -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com