-
Notifications
You must be signed in to change notification settings - Fork 356
/
test1.txt
33 lines (28 loc) · 1009 Bytes
/
test1.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
import arcpy
import arcpy.analysis
import sys
try:
#print (arcpy.GetSystemEnvironment("PATH"))
#environments = arcpy.ListEnvironments()
# Sort the environment names
#environments.sort()
#for environment in environments:
# Format and print each environment and its current setting.
# (The environments are accessed by key from arcpy.env.)
# print("{0:<30}: {1}".format(environment, arcpy.env[environment]))
print(f"Input: {arcpy.GetParameterAsText(0)}")
print(f"Output: {arcpy.GetParameterAsText(1)}")
arcpy.analysis.Buffer(
in_features=arcpy.GetParameterAsText(0),
out_feature_class=arcpy.GetParameterAsText(1),
buffer_distance_or_field="50 Kilometers",
line_side="FULL",
line_end_type="ROUND",
dissolve_option="NONE",
dissolve_field=None,
method="PLANAR"
)
arcpy.AddMessage ("Hello - this message is from a TEST Python script")
except Exception as ex:
arcpy.AddError(f"Exception occurred: {ex}")
print ("Done")