Hello everyone,
I have a problem regarding a small python script for creating a toolbox in ArcGIS Pro. My aim is to create 3D Boreholes in a Scene Layer. For this purpose I first wanted the possibility for the user to enter values regarding the hight in a point feature class.
Until now I created the fields for the values. But now I cant find any solutions for creating the values for each line in the feature class. Should be possible for the user to enter them for each feature in the class...
If anyone knows a possiblity for doing something like this I would be very thankful for some input (where I can look for possible soultions or functions ect.).
import arcpy
arcpy.env.overwriteOutput = False
# Get Value from Raster
wells = arcpy.GetParameterAsText(0)
raster = arcpy.GetParameterAsText(1)
# Process: Extract Values to Points (Extract Values to Points) (sa)
Output_point_features = arcpy.GetParameterAsText(2)
arcpy.sa.ExtractValuesToPoints(in_point_features=wells, in_raster=raster, out_point_features=Output_point_features, interpolate_values="NONE", add_attributes="VALUE_ONLY")
#AddField FromDepth ToDepth
fieldName1 = "FromDepth"
fieldPrecision = 3
fieldAlias = "fromdepth"
fieldName2 = "ToDepth"
fieldPrecision2 = 3
fieldAlias2 = "todepth"
arcpy.AddField_management(Output_point_features,fieldName1, "LONG" , fieldPrecision,
field_alias=fieldAlias, field_is_nullable="NULLABLE")
arcpy.AddField_management(Output_point_features,fieldName2, "LONG" , fieldPrecision2,
field_alias=fieldAlias2, field_is_nullable="NULLABLE")
Thanks in advance and regards,
Nicola