Background color of a subform label

D

DDBeards

I am trying to set the background color of a label on a subform. I can do it
with a "me.fieldname.background=colorcode" but I can not get it to work when
i try using a forms!... statment. Please help


Chris
 
M

Marshall Barton

DDBeards said:
I am trying to set the background color of a label on a subform. I can do it
with a "me.fieldname.background=colorcode" but I can not get it to work when
i try using a forms!... statment. Please help


From code in the main form's module:

Me.subform.Form.label.BackColor = colorcode
 
D

DDBeards

Marshall, are your use of subform and form litteral or do I put the name of
the forms?
 
M

Marshall Barton

in my meta-language, I use lowercase words for things you
need to replace and capitalized words for literal names.

Replace the "subform" with the name of the subform
**control** on the mainform. Form is the name of the
built-in property that returns the form object being
displayed in the subform control.
 
Top