AnsweredAssumed Answered

How to programatically update the dynamic layer name in TOC

Question asked by rickeyttom on Mar 4, 2014
Latest reply on Mar 5, 2014 by ldonahue
This is probably been asked before, but using the search criteria of TOC update label (and others), did not
reveal the answer for me.

When creating a dynamic layer, and adding it to the map, the initial name is "Dynamic Layer".

After initialization or loading of data, I get the real name so I rename that layer programmatically.

However, the name is not updated in the TOC. It is not a repainting issue since I can force a repaint and the new
name does not appear.

When I look at the layer properties, the Layer Name is correct, but not the label on the TOC. When apply is clicked,
the TOC label is updated correctly.


How can I programmatically update the layer name in the TOC