ArcGIS Desktop

  • ArcGIS Pro
  • ArcMap

  • My Profile
  • Hilfe
  • Sign Out
ArcGIS Desktop

ArcGIS Online

Die Mapping-Plattform für Ihre Organisation

ArcGIS Desktop

Ein vollständiges professionelles GIS

ArcGIS Enterprise

GIS in Ihrem Unternehmen

ArcGIS Developers

Werkzeuge zum Erstellen standortbezogener Apps

ArcGIS Solutions

Kostenlose Karten- und App-Vorlagen für Ihre Branche

ArcGIS Marketplace

Rufen Sie Apps und Daten für Ihre Organisation ab.

  • Dokumentation
  • Support
Esri
  • Anmelden
user
  • Eigenes Profil
  • Abmelden

ArcMap

  • Startseite
  • Erste Schritte
  • Karte
  • Analysieren
  • Verwalten von Daten
  • Werkzeuge
  • Erweiterungen

CreateUniqueName

  • Zusammenfassung
  • Syntax
  • Codebeispiel

Zusammenfassung

Creates a unique name in the specified workspace by appending a number to the input name. This number is increased until the name is unique. If no workspace is specified, the current workspace is used.

Syntax

CreateUniqueName (base_name, {workspace})
ParameterErklärungDatentyp
base_name

The base name used to create the unique name.

String
workspace

The workspace used for creation of the unique name.

String

Rückgabewert

DatentypErklärung
String

The unique name with a number appended to make it unique in the workspace. The number starts at 0 and is incremented until it is unique.

Codebeispiel

CreateUniqueName example

Creates a unique name for use with the Buffer and Clip tools.

import arcpy

# Set workspace
arcpy.env.workspace = "c:/data"

# Create a unique name for the Buffer tool's derived output.
unique_name = arcpy.CreateUniqueName("temp.shp")

# Use unique name for Buffer Tool output dataset name
arcpy.Buffer_analysis("roads.shp", unique_name, "100 feet")

# Clip output from Buffer tool with County Boundary to obtain buffered roads
#  in county.
arcpy.Clip_analysis(unique_name, "county.shp", "clipped_roads.shp")

Verwandte Themen

  • CreateScratchName

ArcGIS Desktop

  • Startseite
  • Dokumentation
  • Support

ArcGIS

  • ArcGIS Online
  • ArcGIS Desktop
  • ArcGIS Enterprise
  • ArcGIS
  • ArcGIS Developer
  • ArcGIS Solutions
  • ArcGIS Marketplace

Über Esri

  • Über uns
  • Karriere
  • Esri Blog
  • User Conference
  • Developer Summit
Esri
Wir sind an Ihrer Meinung interessiert.
Copyright © 2021 Esri. | Datenschutz | Rechtliches