Labels and Text Fields

oskar

Registered User.
Local time
Today, 13:52
Joined
Jul 9, 2013
Messages
69
I have a problem with the connection between the labels and fields in designing my form and searching I found some tips but still not a big help.
Is there a command do eliminate the association between the two?

If not I was thinking if there is a problem to delete the labels and make new ones but by doing this Access (2010) says the label is unassociated. Is this a problem?
 
Select the textboxes, right click and select Layout/Remove.
 
The labels are associated by a Controls Collection on the control it is associated with.
This expression will return the name of the associated label.

Code:
Forms!formname!controlname.Controls(0).Name

However this collection is read only so AFAIK there is no code to remove the association.

You can respond to the unassociated label message telling it to ignore.
 
You can also leave the label associated and drag it separately from the associated control by using the handle at the top left corner.
 
The Layout/Remove is always greyed out and using the handle at the top left corner does not always works. To me the best solution is to delete the labels, make new ones and ignore the error .
 
1. Highlight all the labels
2. Cut them
3. Select the section (i.e. Detail section) and paste

That will disassociate them from their controls. And the warning you get about "unassociated label" is fine.

You can also do this in code but there's really no point when you can easily do it via the GUI.
 

Users who are viewing this thread

Back
Top Bottom