ArcGIS for Desktop

  • Documentation
  • Pricing
  • Support

  • My Profile
  • Help
  • Sign Out
ArcGIS for Desktop

ArcGIS Online

The mapping platform for your organization

ArcGIS for Desktop

A complete professional GIS

ArcGIS for Server

GIS in your enterprise

ArcGIS for Developers

Tools to build location-aware apps

ArcGIS Solutions

Free template maps and apps for your industry

ArcGIS Marketplace

Get apps and data for your organization

  • Documentation
  • Pricing
  • Support
Esri
  • Sign In
user
  • My Profile
  • Sign Out

Help

  • Home
  • Get Started
  • Map
  • Analyze
  • Manage Data
  • Tools
  • More...

Create Territory Solution

  • Summary
  • Usage
  • Syntax
  • Code Sample
  • Environments
  • Licensing Information

Summary

Creates a new Territory Solution with one empty territory level.

Usage

  • The Polygon and Point layers to be used as an Alignment Layer for the new Territory Solution.

  • A String, Integer, SmallInteger, Double, Single, Date, OID, GlobalID or GUID field of Alignment Layer can be used as the Display Field. The default value is the Alignment Layer’s display field. If the Alignment Layer’s display field is not defined the first suitable field will be applied.

  • If unspecified, the default Territory Level Name will be read from the ATDConfig.xml file.

  • By default, the Territory Solution Location is under the "Territories" folder in the current BA project.

  • A default Territory Solution Name is generated if not specified.

Syntax

CreateTerritorySolution_TD_td (in_alignment_layer, {in_display_field}, {in_level_name}, {in_territory_solution_location}, {in_territory_solution_name})
ParameterExplanationData Type
in_alignment_layer

The Alignment Layer for the new Territory Solution.

Feature Layer
in_display_field
(Optional)

The Display Field for the Territory Solution.

Field
in_level_name
(Optional)

The name of the first territory level.

String
in_territory_solution_location
(Optional)

The location of the Territory Solution.

String
in_territory_solution_name
(Optional)

The name of the Territory Solution.

String

Code Sample

CreateTerritorySolution example (Python window)

The following Python window script demonstrates how to use the tool in immediate mode.

import arcgisscripting
gp = arcgisscripting.create()
gp.CreateTerritorySolution_TD("esri_zip5", "NAME", "Territories", "C:/BA Output/Project/Default Project/Territories/", "new layer")
CreateTerritorySolution example2 (stand-alone script)

The following stand-alone script demonstrates how to use the tool.

# Import system modules
import arcgisscripting
gp = arcgisscripting.create()

# Set local variables
alignmentLayer = "esri_zip5"
displayField = "NAME"
levelName = "Territories"
solutionLocation = "C:/BA Output/Project/Default Project/Territories/"
solutionName = "new layer"

# Execute tool
gp.CreateTerritorySolution_TD(alignmentLayer, displayField, levelName, solutionLocation, solutionName)

Environments

This tool does not use any geoprocessing environments

Licensing Information

  • ArcGIS for Desktop Basic: Requires Business Analyst
  • ArcGIS for Desktop Standard: Requires Business Analyst
  • ArcGIS for Desktop Advanced: Requires Business Analyst

Related Topics

  • An Overview of the Create Territory Solution Toolset
  • Delete Territory Solution
  • Build Territory Index
  • Import Territory Solution
Feedback on this topic?

ArcGIS for Desktop

  • Home
  • Documentation
  • Pricing
  • Support

ArcGIS Platform

  • ArcGIS Online
  • ArcGIS for Desktop
  • ArcGIS for Server
  • ArcGIS for Developers
  • ArcGIS Solutions
  • ArcGIS Marketplace

About Esri

  • About Us
  • Careers
  • Insiders Blog
  • User Conference
  • Developer Summit
Esri
© Copyright 2016 Environmental Systems Research Institute, Inc. | Privacy | Legal