I am trying to use the Grid Index Features to generate a grid based on scale and extent. I want to dynamically determine the number of rows and columns, just like the tool dialog does. Is there anyway to calculate these values dynamically based on the extent and scale?
![Grid Index Features dialog](/legacyfs/online/454225_Grid Index Features dialog.png)
Here is the Python code I am trying to use. However, no matter what I try, the number of rows and columns defaults to 10.
arcpy.GridIndexFeatures_cartography(Grid_Index_FC, Buffered_Extent_FC,
intersect_feature="NO_INTERSECTFEATURE", use_page_unit="USEPAGEUNIT",
scale=2000, polygon_width="4 Inches", polygon_height="4 Inches",
#origin_coord=orig_coord,
#number_rows="", number_columns="",
starting_page_number="1", label_from_origin="NO_LABELFROMORIGIN")