L
Larry
I have a subroutine that investigates controls on a form, returning
information about those controls. The subroutine accepts the name of
the form, which I then assign to a form object using SET frm =
FORMS(strFormName), but of course, if the form isn't open, this doesn't
work.
I need to be able to investigate an instance of the form, whether it's
open or not, so I can search each control. If it's open, I can't
disturb the form, that's why I want a new instance.
I have tried using the AllForms collection of CurrentProject, but I
can't assign the object that returns to a Form variable. I have also
tried using the Documents collection, with the same results of not
being able to convert it to a form variable.
I could probably check to see if the form is loaded, and use the
statement above, then if it's not open, open it hidden then use the
statement above, but that seems cumbersome. Is there any better way to
do it?
Thanks,
Larry
BTW, this is Access 2003.
information about those controls. The subroutine accepts the name of
the form, which I then assign to a form object using SET frm =
FORMS(strFormName), but of course, if the form isn't open, this doesn't
work.
I need to be able to investigate an instance of the form, whether it's
open or not, so I can search each control. If it's open, I can't
disturb the form, that's why I want a new instance.
I have tried using the AllForms collection of CurrentProject, but I
can't assign the object that returns to a Form variable. I have also
tried using the Documents collection, with the same results of not
being able to convert it to a form variable.
I could probably check to see if the form is loaded, and use the
statement above, then if it's not open, open it hidden then use the
statement above, but that seems cumbersome. Is there any better way to
do it?
Thanks,
Larry
BTW, this is Access 2003.