T
TIm
Hi,
I am just learning about VBA class modules. For starters
I was trying to replace a set of functions with a custom
class. My class is "Person." In the startup module I do
this:
Public objThisUser As New Person
And then this:
objThisUser.PersonID = fLoggedInUserID()
In the application I refer to properties like so:
objThisUser.FullName
instead of how I used to:
fLoggedInUserFullName()
I would like to retire the person function in favor of the
class. However, I use these functions queries, form
recordsources, form controls etc. Is there any way to
refer to this object in a controlsource or query, etc. Or
do I need to keep my functions for this?
Thanks,
Tim
I am just learning about VBA class modules. For starters
I was trying to replace a set of functions with a custom
class. My class is "Person." In the startup module I do
this:
Public objThisUser As New Person
And then this:
objThisUser.PersonID = fLoggedInUserID()
In the application I refer to properties like so:
objThisUser.FullName
instead of how I used to:
fLoggedInUserFullName()
I would like to retire the person function in favor of the
class. However, I use these functions queries, form
recordsources, form controls etc. Is there any way to
refer to this object in a controlsource or query, etc. Or
do I need to keep my functions for this?
Thanks,
Tim