I had the same question and figured out a solution for me but I will elaborate on the issue before in case it is the same problem you are having.
I did find a workaround that worked for me so I put what I did below as well as a suggestion you can try in case my workaround is not an exact fit. Also, I hope by putting in more information about my initial issue that maybe someone can give alternate solutions that maybe work better.
The layers in the scenario
- I have a master layer that shows all the polygons for the area. It has a specific symbology and labeling expression.
- I have a child shapefile for just the polygons I am highlighting in my drawing. This layer has it's own symbology and label expression.
What I was trying to accomplish
- Hide the labels from the master layer with respect to the Child shapefile
- only show the labels for the child layer in the child layer polygons (not both the master layer's labels and child layer's labels)
What I tried
- I tried to find a way to hide the labels for the master shapefile by creating a mask
- I tried putting the master layer labels into the annotation.
What worked
- I looked at the master shapefile attribute table and noticed that there was a column that denoted each polygon as active, pending or retired.
- I then created a definition query on the master file to only show the active polygons.
Suggestion
- If you do not have a column in your 'master file' that helps you determine the polygons you want to label, insert a column into your 'master file', and fill the cells for all polygons you do want to label (so for all but those that intersect your 'child file')
- Create a definition query in your 'master file' to only label the polygons you want to be labeled. (see the example of an attribute table below)
- Definition query based on example table below would look like --> [COLUMN_NAME] = [LABEL]
Example of master shapefile attribute table after adding the column called [COLUMN_NAME] and filling cells for the polygons I do want to label.
FID | SHAPE | OBJECTID | BLOCK | COLUMN_NAME |
0 | Polygon | 1 | A | LABEL |
1 | Polygon | 2 | B | LABEL |
2 | Polygon | 3 | C | LABEL |
3 | Polygon | 4 | D | <NULL> |
4 | Polygon | 5 | E | <NULL> |
5 | Polygon | 6 | F | LABEL |
6 | Polygon | 7 | G | <NULL> |
7 | Polygon | 8 | H | LABEL |
I hope this helps.