2 Replies Latest reply on May 7, 2012 8:01 AM by jbarrette-esristaff

    editing text in data frame


      I think the answer is no, but I have to ask anyway.

      The situation - we have produced about 150 maps for a report. At this point, someone has realized that we shouldn't be calling a particular road X Road. That is an old and informal name. Instead we should be calling it Y Road. The road name is annotation in the data frame, not an attribute of the road feature class. We are not too keen on opening up every map and doing this edit manually.

      The question - I know it is possible with Python to access and update text strings in the layout, but is it possible to access/edit text strings in the data frame?


        • Re: editing text in data frame
          What were you thinking! GIS is supposed to be a "database approach to mapping", so to be able to manipulate data it needs to be in a database, as annotation tables as a minimum. Well never mind.

          The best thing to do would be to use the tool on the Drawing toolbar to 'Convert Graphics to Features' (annotation features). Then you can make a single feature layer and use that instead of the graphics. The text content can be edited in the feature table just like any other featureclass. You will have to use the interactive tool unless you use ArcObjects to get access to the tool, which is not directly supported in ArcPy.

          Perhaps you can automate the 150 maps into one MXD with data driven pages? Then you would only have to open one MXD to fix it.
          • Re: editing text in data frame
            You could do this with ArcObjects.  Elements added to the data frame can be retrieved and modified via the graphic elements interface.  The last sample in the like below shows how to add a new map element.  In you case, you simply want to find and change an existing element.


            It would be convienient if we could find/replace map elements via arcpy.  You may want to add it to the ideas site.