Data Driven Pages - Series Index

5486
28
04-20-2010 09:14 AM
JacobTerstriep
New Contributor II
Is there a way in the new data driven pages to easily create a series index based on a specific feature and series page number and/or grid number.  For example with map book i was able to create a series index for a centerline file in relation to what page number and grid section, ie maple street - Pg 5 -  D6, and export that list to an excel file.
This was a very handy one step process within DS Map Book
0 Kudos
28 Replies
marieducharme
Occasional Contributor
Ah! If I could roll back to 9.3.1!

I am trying to make a map series index....from reading this thread, it looks like I am out of luck. I guess ESRI has not released the python script that stuart.blumberg is refering too.

Gee, thanks ESRI, now we create an index unless we still have a PC with 9.3 that still is compatible with the good ol' DS Map Book.

sigh.
0 Kudos
KimOllivier
Occasional Contributor III
I have a mapbook with 1,440 pages that label neighboring tiles and I do not see a good reason to upgrade to 10 based on what I have tried and have read.

Also what is a good way to export random pages, I do not use page numbers but a name instead.

jim


There is a fine example Python based tool that creates a dialog with map sheet names instead of numbers on the resource pages. I know it is so hard to find these, no arcscripts search now, so here is the whole script unzipped:
from Tkinter import *
import arcpy

# SelectPopup.py sample Python script using Tkinter for a user interface
# User selects feature from list, code selects and zooms to feature
# Works with file geodatabases and sdc datasets

# Use in ArcMap by attaching script to a button for best results
# In ArcGIS 10, you can add scripts and models to buttons in the UI without using VBA.
# See "Adding a custom tool to a menu or toolbar" in this help topic:
# http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#//002400000005000000.htm

# Replace the values for the 4 variables below to match your data
# if you change the variable name, be sure to modify the code
# below to match.
# Layer on which the selection will be performed
Layer = "states"
# Table or feature class with field containing unique list of feature names to use for selections
# Can be the data source for the layer above or a separate table. Use a separate table containing
# only the valid names if there are large numbers of blank or non-unique names or a definition query
# on the layer.
# SelTable = "D:\Work\Demos\Done\Arkansas10\GeoStor.gdb\NRHP_YrBlt"
SelTable = "D:\Work\ESRIData&Maps\mexico\data\states.sdc\states"
# Name of field in SelTable and Layer that contains feature names
SelField = "ST_NAME"
# Title to Appear on Dialog
Title = "Select A State"
# End of section for entering your data parameters


class Application(Frame):            
    def __init__(self, master=None):
        Frame.__init__(self, master)
        self.grid()      
        self.createWidgets(master)

    def createWidgets(self, master):
        self.yScroll  =  Scrollbar ( self, orient=VERTICAL )
        self.yScroll.grid ( row=0, column=1, sticky=N+S )
        self.stList = Listbox (self, yscrollcommand=self.yScroll.set)
        self.stList.grid( row=0, column=0 )
        self.yScroll["command"] = self.stList.yview
        #populate list with choices, sorted ascending
        rows = arcpy.SearchCursor(SelTable, "", "", SelField, SelField + " A")
        for row in rows:
            self.stList.insert( END, row.getValue(SelField) ) 
        #add selection and quit button
        self.selButton = Button (self, text='Select', command=self.selectFeat)
        self.selButton.grid( row=0, column=2 )
        self.quitButton = Button ( self, text='Quit', command=master.destroy )    
        self.quitButton.grid( row=1, column=2 )

    def selectFeat(self):
        sel = self.stList.curselection()
        myState = self.stList.get(sel[0])
        arcpy.SelectLayerByAttribute_management(Layer, "NEW_SELECTION", "\"" + SelField + "\" = '" + myState + "'")
        mxd = arcpy.mapping.MapDocument("CURRENT")
        for df in arcpy.mapping.ListDataFrames(mxd):
            if df.name == mxd.activeView:
                df.zoomToSelectedFeatures()
                arcpy.RefreshActiveView()
        

root = Tk()
app = Application(master=root)                   
app.master.title(Title)
app.mainloop()
0 Kudos
KimOllivier
Occasional Contributor III
Note to ArcView users (myself included), you won't be able to use the solution found in the link, as this tool references two other toolbox tools (Point to Feature and Frequency) that are not available at the ArcView license level.

How and why this functionality was essentially left out is maddening to me, ha. /end rant


I keep getting caught by this too. I build a tool for ArcView with a higher licence, then it won't work on my laptop. You don' need to use Frequency.

Frequency_analysis is a hangover from the ArcInfo tools.

There is an equivalent Arcview level tool called Summarize_analysis that includes all the functionality of Frequency and more! I am sure that Esri did not intend us to have to upgrade just to count features.
http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#//00080000001z000000.htm

FeatureToPoint is an ArcInfo tool, but for goodness sake, if you insist on using a viewer for analysis, then get cracking with your own Python script to replace this tool. It isn't  very hard to run a cursor and get out the centroid of each feature to export as a point layer, it's built into the basic toolkit for Arcview. I can't see why it is a higher licence myself, maybe it is to encourage us to learn Python (or keep a third party addin such as the excellent ETGeotools in business).

Everything that was in DS Mapbook can be done with data driven pages and a couple of free scripts that are much easier to modify than the DS Visual Basic. After all DS (Developer Sample) was an add-in itself, it was not part of the base. It is no reason not to upgrade IMHO.
0 Kudos
JeffBarrette
Esri Regular Contributor
I really appreciate postings like these. It is what the forums are all about.

The sample that this posting references was really about integrating arcpy.mapping with DDP and ReportLab. The main sample will run using an ArcView license.

http://resources.arcgis.com/gallery/file/geoprocessing/details?entryID=FBE3D235-1422-2418-8820-E071E...

The issue is the outlined ArcInfo level analysis I used to format the source table. I would be happy to update the sample with additional steps/scripts. Please send me what you have and I'll integrate it into the sample notes - jbarrette@esri.com

Thanks,
Jeff
0 Kudos
JeffBarrette
Esri Regular Contributor
I completely re-wrote the Map Book with Street Index Pages sample so that it will work with an ArcView license. 

There is a very complete README file that covers everything in great detail from A to Z.

http://resources.arcgis.com/gallery/file/geoprocessing/details?entryID=FBE3D235-1422-2418-8820-E071E...

Jeff
0 Kudos
JustinRichardson
New Contributor III
if you can't write code very well, you can still make an index by doing the following:

Use intersect to clip your street layer to the index and split your street lines at the index lines.  This will also add the page name and number of your index to the street line segment.
use the dissolve tool to dissolve the data by street name and index page name and/or number.

now you can export the .dbf to excel to make it look pretty.
0 Kudos
ScottJackson1
New Contributor II
I have come up with a simple solution to the dreaded Create Street Index. Just read the README to see how it works. I do hope this helps.
0 Kudos
JenniferDick
New Contributor II
Hi

I�??m creating a map book using data driven pages, however I need to delete index features as they do not show anything of value within that grid. You�??ll see the image attached to the email, there is basically 2 distinct areas in the County that I need to make a one map book for. The grid index needs to follow the Bow River, but I do not need to include the portion of the river that runs through Calgary.

Would you have any suggestions for me? I can go into editing mode and delete those grids I do not need, but I�??m afraid it will confuse my page numbering.

I appreciate your thoughts and time on this,

Thanks,
Jenn[ATTACH=CONFIG]12233[/ATTACH]
0 Kudos
JeffBarrette
Esri Regular Contributor
I assume you are using the Grid Index Features tool to automatically generate your index polygons along with page numbering.  Couldn't you make a backup copy of your Input Features, modify it to exclude the areas you don't want to generate index areas, and use that layer in the Grid Index Feature tool?

Jeff
0 Kudos
MattTenold
New Contributor III
Hi I downloaded the Python and Report labs street index demo app, however I am wondering if I can create a street index on each page instead of at the end of the pdf document.  I tried commenting out parts of the code to figure out how the code works but I still cannot figure out how to remove the Legend, Scale and index map, and place an index of all the roads within each page of my mapbook.  Here is the program I downloaded. http://resources.arcgis.com/gallery/file/geoprocessing/details?entryID=FBE3D235-1422-2418-8820-E071E...

Thanks
0 Kudos