I want to create a Python Script for ArcGIS, using
The script would have several user input fields. I would like to create a table based on one or two of the user input (the
I am trying :
import arcpy import os from arcpy import env from arcpy.management import CreateFeatureclass workspace = arcpy.GetParameterAsText(0) poly = arcpy.GetParameterAsText(1) poly_nou = arcpy.GetParameterAsText(2) input_areas = arcpy.GetParameterAsText(3) direction = arcpy.GetParameterAsText(4) env.workspace = workspace out_path = os.path.split(poly_nou) name = os.path.split(poly_nou) arcpy.CreateTable(out_path, name)
I have set up the Script in ArcMap to look like this: 1. Workspace type 2. Feature class 3. Table 4 and 5 Strings
I want the script to read 3 (possibly also 1) and create a table.
I get the error:
Traceback (most recent call last): File "C:\Users\user\Documents\Proiecte\Python Toolbox\Divide_percentage.py", line 16, in arcpy.CreateTable(out_path, name) AttributeError: 'module' object has no attribute 'CreateTable' Failed to execute (Script1).