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

GetParameterAsText

  • Zusammenfassung
  • Auswertung
  • Syntax
  • Codebeispiel

Zusammenfassung

Gets the specified parameter as a text string by its index position from the list of parameters.

Auswertung

Any value regardless of the parameter data type will be returned as a string; to use the parameter as an ArcPy or Python object instead, see GetParameter.

Syntax

GetParameterAsText (index)
ParameterErklärungDatentyp
index

The numeric position of the parameter in the parameter list.

Integer

Rückgabewert

DatentypErklärung
String

The value of the specified parameter, returned as a string.

Codebeispiel

GetParameterAsText example

Get specified parameter as text string.

import os
import arcpy

# Set the input workspace, get the feature class name to copy
#  and the output location.
arcpy.env.workspace = arcpy.GetParameterAsText(0)
in_featureclass = arcpy.GetParameterAsText(1)
out_workspace = arcpy.GetParameterAsText(2)

out_featureclass = os.path.join(out_workspace,
                                os.path.basename(in_featureclass))

# Copy feature class to output location
arcpy.CopyFeatures_management(in_featureclass, out_featureclass)

Verwandte Themen

  • CopyParameter
  • GetArgumentCount
  • GetParameter
  • GetParameterCount
  • GetParameterInfo
  • GetParameterValue
  • SetParameter
  • SetParameterAsText
  • Festlegen von Parametern für Skriptwerkzeuge

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