AnsweredAssumed Answered

inserting text in map layout

Question asked by dabera on Dec 5, 2012
Latest reply on Dec 6, 2012 by dabera
Hi Guys,

I was wondering if it is possible to insert all possible values of a loop into map layout as a text element. The script I have prints only one value or line. Here is part of my code. Thanks for your help !!

Daniel A.

arcpy.AddMessage('Adding Text Elements...')  arcpy.AddMessage('*************************')  # search input feature rows=arcpy.SearchCursor(inputFc)  # Retrieve the first record from the list  # set field value list FieldValList = []  # loop through the field ATS while row:       feat=row.shape             total=total+feat.area       ATS = row.getValue("ATS")                             # make sure its unique       if not ATS in FieldValList:                     FieldValList.append(ATS)                                                                                                                                   # next field                                                                      # add text elemets to the map layout        for elm in arcpy.mapping.ListLayoutElements(mxd, "TEXT_ELEMENT"):           if == "ATSList":                 elm.elementPositionX = 6.5                 elm.elementPositionY = 1.0                 for ATS in FieldValList:                                elm.text = "Within Theoretical: " + "\n" + ATS