I have a point layer and i need to connect all the points(4046) with each other. I tried it through python console from Arcgis but it gives me run time error. Here is my code :
import arcpy cursor = arcpy.da.SearchCursor("vertex_final",['POINT_X','POINT_Y']) outlines= r"C:\Users\stelitsa\Desktop\descriptive_data" i = 0 while (i<4064): X1=row[i] Y1=row[i+1] print X1, Y1 for row in cursor: X2=row Y2= row if X1!=X2: arcpy.XYToLine_management(cursor,outlines,X1,Y1,X2,Y2,"GEODESIC","id")
And here is the error :
Runtime error Traceback (most recent call last): File "", line 13, in File "c:\program files (x86)\arcgis\desktop10.4\arcpy\arcpy\management.py", line 3063, in XYToLine raise e RuntimeError: Object: Error in executing tool
This is the first time that I have used Python.