[AccessD] SPAM-LOW: Re: Access 2007 accde User Security

Robert robert at servicexp.com
Wed Jan 27 06:34:24 CST 2010


John,
 Ok that helped a bunch, because there's a lot of 'other' stuff in that
db.... ;-) 

BIG Thanks to you, I have been working with classes ever since your very
first class introduction several years ago, and can really appreciate the
beauty in function that a class object provides. 

Unfortunately for me, it was after I had written most of the code for my
main program. For the last couple of years I've been slowly breaking it down
into much more powerful class objects.

When I briefly looked at all the "stuff" in their I was like HOLY COW, what
in the **** could all this possibly do with LWS ... ;-)

Thanks Again

WBR
Robert

PS: The Administrator credentials appear to be incorrect (the password)




 

-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of jwcolby
Sent: Tuesday, January 26, 2010 11:05 PM
To: Access Developers discussion and problem solving
Subject: Re: [AccessD] SPAM-LOW: Re: Access 2007 accde User Security

 >  HOLY COW John... It's going to take me a month just to understand what
in the world is going on 
in there...

Naw, it's easy.  There are three tables - Users, Groups and UsersInGroups.

There are three classes - User (usysclsPLSUser), Group (usysclsPLSGroup) and
UsersInGroups 
(usysclsPLSGroupUser).  Each instance of these classes holds ONE RECORD for
the corresponding table. 
     Each instance of usysclsPLSUser holds one record from usystblPLSUsers,
etc.

There is a supervisor class (usysclsPLS).  This class is the center of the
universe.  It loads all 
of the other stuff.  It forms a cache.  It completely loads the user table
usystblPLSUsers into 
instances of usysclsPLSUser and stores the class instances in a collection.
Likewise for the Group 
and UserGroup tables.

There is a module for initializing the thing - usysBasPLS.  It initializes
usysclsPLS which loads 
(caches in memory) the three tables.  mPLSInit.  Once that runs the entire
system is loaded and 
ready to rock and roll.  Please tell me you are not into Opera - C2DbPLS
does not do Opera.  ;)

mclsPLS.mInit is the initialization method of the supervisor class.  Go
there to watch it start 
loading the cache.

Once mclsPLS is initialized, you can start asking questions such as "Does
user X belong to Group A".

Function mPLSUserInGroup(lngPLSUserID As Long, ParamArray lngGroups() As
Variant) As Boolean

Call mPLSUserInGroup, pass in a single user ID and as many group IDs as you
want to check.

Look at the other methods in that module for other questions you can ask.

The rest of the classes are "to be continued...".  You only need to
concentrate on the pieces 
described above.

 >Your use of classes as objects "out classes" my understanding. It's on a
whole different level, 
like several different levels, than where I'm at....

Look at it this way, this is the perfect opportunity to see how classes can
do things that are 
damned near impossible without them.  Pre-written code that you can step
through.  Me to ask 
questions of.

 > Damn....

You too can be a Jedi Master.  ;)

I am not kidding, once you wrap your mind around classes the universe
balloons around you.


John W. Colby
www.ColbyConsulting.com


Robert wrote:
> Got it.....
> 
>  HOLY COW John... It's going to take me a month just to understand what in
> the world is going on in there... Your use of classes as objects "out
> classes" my understanding. It's on a whole different level, like several
> different levels, then where I'm at....
> 
> Damn....
> 
> WBR
> Robert

-- 
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com





More information about the AccessD mailing list