I would like to convert polyline shapefile into point shapefile using Python.
First I shall create a list of polyline points from polyline shapefile and second write point shapefile from previous list.
There is a lot of pieces of code for first and second step apart but not put together.
I think problem is because of list formatting.
fc = "polyline.shp"
array = arcpy.Array()
with arcpy.da.UpdateCursor(fc, ("OID@", "SHAPE@")) as curs:
for point in row .getPart(0):
# Make some points
point = arcpy.Point(point.X, point.Y)
# Put the points in the array
for x, y in array:
pointGeometry = arcpy.PointGeometry(point)
I am using Pytohn only sometimes so any help would be appreciated.