The above disassociates the label text from the original table. OK, so no progress afterall. If some part of the label text changes in the original table, I have to go through the process of re-creating the label drawing then the labels component, then manually reposition the labels again so that the labels are not directly over top of the areas. I'll explore relations between tables next.
Well, no, you do have progress if what you want is to manually position labels derived from areas. If you want to do that and you also want automatic updates to label text, well, then you need some more progress. :-) Labels created directly from areas are positioned by the system and not always at a centroid of the area. For example, when zoomed in so that some areas are only partially visible, the system will move labels into the part of the area that is visible, so more areas that are in view have labels. If you want to change that you can decouple the geometry used to position the labels from the geometry of the area. The most common way of doing that is to create a point from the area, either manually or dynamically. For example, you could add a Cent_Geom field to the table that is a computed field which generates the centroid of the area, and then create a drawing for those centroids and then a label from that centroids drawing. The labels will then always be at the centroid, but, because a computed field is read-only you won't be able to drag those points to some other position. However, if you add or delete areas, or if you edit areas to change their shape, the centroids will be automatically added/deleted/moved, as will any labels based on them. Another way is to add a Points_Geom field (these names don't matter... I'm just making them up) to the table that is a Geom field, and to then use the Copy transform template using a centroids expression, like GeomMakePoint(GeomCenter([Geom], 0)) to populate the Points_Geom field with the centroid of each area. This is a one-time deal, not a dynamic computed field. You can then create a drawing from the Points_Geom field and create labels from that drawing. You'll now be able to move those labels around. If the text field in the table for the record (same record for the area and for the Points_Geom field) changes, the label text will change. However, when creating points that way if you add an area there won't be a new point automatically created in the Points_Geom field. It will just be a NULL until you copy something into it. If some part of the label text changes in the original table, I have to go through the process of re-creating the label drawing then the labels component,
That doesn't sound right if you did the last thing I suggested above.
|