which one is form name

  • Thread starter Thread starter babs
  • Start date Start date
B

babs

I am having a hard time getting the syntax right for a control on a subform.

I have the table that tells you

use
forms!mainform!subform1.form!controlName

but I have Forms and subforms for some reason the Object Name listed is not
always the same name that I have for the Caption property for the form. and
do you use the Name for the controlbox not the record source.

What is the real name??? you use for the subform?

thanks,
Barb
 
Babs,

This might help...

http://www.mvps.org/access/forms/frm0031.htm

--
Gina Whipp
2010 Microsoft MVP (Access)

"I feel I have been denied critical, need to know, information!" - Tremors
II

http://www.regina-whipp.com/index_files/TipList.htm

I am having a hard time getting the syntax right for a control on a
subform.

I have the table that tells you

use
forms!mainform!subform1.form!controlName

but I have Forms and subforms for some reason the Object Name listed is not
always the same name that I have for the Caption property for the form. and
do you use the Name for the controlbox not the record source.

What is the real name??? you use for the subform?

thanks,
Barb
 
I am having a hard time getting the syntax right for a control on a subform.

I have the table that tells you

use
forms!mainform!subform1.form!controlName

but I have Forms and subforms for some reason the Object Name listed is not
always the same name that I have for the Caption property for the form. and
do you use the Name for the controlbox not the record source.

What is the real name??? you use for the subform?

thanks,
Barb

A Form has a Name property. It also has a Caption property. These are
independent; you need the main form's Name property (not its Caption) in the
mainform slot above.

A Form may have a Subform Control on it. This isn't the form, it's the box
containing the form; the Subform Control has a Name property and a
SourceObject property. The Name property of the Subform control is what goes
in subform1 in the syntax above.

The Name of the form *inside* that box - the SourceObject - is not used in
referencing controls on the subform, just the name of the box (the Subform
Control object).
 
Back
Top