Hello,
In the last few days I've been working on a Python script that enables me to draw lines in a feature class.
The script gets 3 params - starting point coordinates, angle (degree) and length in km.
After a few hours of investigating for possible implementations, I've decided to drop the mathematical approach and use the pre-made tool called BearingDistanceToLine_management.
My current implementation actually works but the designed is ridiculous! The tool requires two special tables!
I have one table that holds the parameters - I actually do an InsertCursor into a table just for the tool to run!
I have another table, which gets the output when the tool is finished.
When the tool is done, I run a searchCursor on the output table, take the output shape data and adds it into a THIRD and final table where I can add my own other columns.
Can anyone recommends a better solution? I have found many articles with a lot of math lessons but no clear solid answer how to do it. I can't waste my time on learning trigonometry for this and pretty surprised ESRI doesn't have a simple pre-made function for that.
Thanks,
Shay.