O'Reilly logo

Programming ArcGIS 10.1 with Python Cookbook by Eric Pimpler

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Accessing a data frame

The ArcMap table of contents is composed of one or more data frames. Each data frame can contain layers and tables. Data frames can be used to filter lists that are returned from the various list functions such as ListLayers(). For example, a DataFrame object can be used as an input parameter to restrict the layers returned by the ListLayers() function to only those layers within a particular data frame. You can also use a DataFrame object to get or set the current map extent, which can be useful when creating map books. In this recipe you will learn how to access data frames from your Python scripts.

Getting ready

The ListDataFrames() function returns a list of DataFrame objects. Each data frame can hold layers and tables ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required