Label naming in tab controls

B

Ben Thomason

If I try to display the same field from a query in
multiple tabs of a tab control only the first instance
shows the correct label name. All other instances simply
show "Text" as the label. Is there any way to display the
same field on multiple tabs without having to manually
change the label so that they are all the same?
 
A

Al Campagna

Ben,
Since you already had a label called (ex. lblAcctNo) when you created
copies on other tabs, Access won't use the same name for them. Since Labels
can be addressed programatically, it would violate the Access "naming" rules
to have duplicate label names.
It's the same rule for any control on a form (text, List, combo, etc..).
No objects on a form can have the same name.
You'll need to give each a unique name, such as...
lblAcctNo1, lblAcctNo2, etc...
 
R

Rick Brandt

Ben Thomason said:
If I try to display the same field from a query in
multiple tabs of a tab control only the first instance
shows the correct label name. All other instances simply
show "Text" as the label. Is there any way to display the
same field on multiple tabs without having to manually
change the label so that they are all the same?

If you place the control on the form instead of on a TabControl page, then you
can position it "behind" the TabControl and you will see it on all pages without
having to create multiple copies. That assumes you want to see it in the same
place on all Tab Pages though.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top