スケマティック フォルダの作成(Create Schematic Folder) (スケマティック)

ライセンス レベル:BasicStandardAdvanced

サマリ

スケマティック データセットまたはスケマティック フォルダにスケマティック フォルダを作成します。

使用法

構文

CreateSchematicFolder_schematics (out_location, out_name)
パラメータ説明データ タイプ
out_location

フォルダの作成先のスケマティック データセットまたはスケマティック フォルダ。このコンテナはすでに存在している必要があります。

Schematic Dataset;Schematic Folder
out_name

出力スケマティック フォルダの名前。

String

コードのサンプル

CreateSchematicFolder の例(スタンドアロン Python スクリプト)

スケマティック データセットにスケマティック フォルダとサブフォルダを作成します。

この Python スクリプトの例の実行方法は次のとおりです。

  1. ArcCatalog を起動します。
  2. 以下のスクリプトをコピーして Python ウィンドウに貼り付けます。
  3. Enter キーを押します。

# Name: CreateSchematicFolder.py
# Description: Create a schematic folder and subfolder
# Requirement: ArcGIS Schematics エクステンション

# import system modules
import arcpy
msgNoLicenseAvailable = "ArcGIS Schematics エクステンション license required"

try:
    # Checks out the ArcGIS Schematics エクステンション licence
    if arcpy.CheckExtension("Schematics") == "Available":
        arcpy.CheckOutExtension("Schematics")
    else:
        raise Exception(msgNoLicenseAvailable)

    # Sets environnement settings
    arcpy.env.overwriteOutput = True
    arcpy.env.workspace = "C:\ArcGIS\ArcTutor\Schematics\Schematics_In_ArcMap\ElecDemo.gdb"

    # Creates a new schematic folder, MySchematicRootFolder, at the ElecDemo schematic dataset root.
    arcpy.CreateSchematicFolder_schematics("ElecDemo", "MySchematicRootFolder")

    # Creates a schematic subfolder, MySchematicSubFolder, in a schematic folder, MySchematicRootFolder.
    arcpy.CreateSchematicFolder_schematics("ElecDemo\MySchematicRootFolder", "MySchematicSubFolder")

    # Returns the ArcGIS Schematics エクステンション licence
    arcpy.CheckInExtension("Schematics")
   
    print "Script completed successfully"

except Exception as e:
    # If an error occurred, print line number and error message
    import traceback, sys
    tb = sys.exc_info()[2]
    print "An error occured on line %i" % tb.tb_lineno
    print str(e)

環境

このツールはジオプロセシング環境を使用していません

関連トピック

ライセンス情報

ArcGIS for Desktop Basic: 次のものが必要 スケマティクス
ArcGIS for Desktop Standard: 次のものが必要 スケマティクス
ArcGIS for Desktop Advanced: 次のものが必要 スケマティクス
5/10/2014