I have three fixed points and a number of lines I would like to draw that radiate out from each point. I have tried to use the bearing distance to line tool but it keeps failing for some reason and I'm not exactly sure how to draw my lines otherwise. I am using the angle field for the bearing and this is in degrees (I think...the values fall between 0 and 360). And my distance field is the 20yrSpread field which is in KM.
Any help is greatly appreciated...see the attached table.
No, I ran this directly from the provided Excel file. I just highlighted the zero distance rows in Excel, right-click delete (don't leave blank rows by pressing delete key), save Excel, then run Bearing Distance to Line tool on Excel file. That said, sometimes Excel files cause funky issues and can vary between versions of Excel and ArcGIS, so don't be shocked if it doesn't work in .xlsx format.
Arc did allow me to bring the CSV file in with numbers at the beginning of field names, but when that table is exported into a gdb then the field names are changed to include an "F" at the beginning of the numeric field name.
Also, thanks Dan for links. I'll check into those and try not to create poorly constructed excel files.
So in summary...
the tools allows you to work with ill-formed data files without checks for the things that will cause it to crash.
There are several links on how to work with excel files, which are quite good, unfortunately, the advice therein is not checked by the tool itself.
And there are a few help file topics
Understanding how to use Microsoft Excel files in ArcGIS—Help | ArcGIS for Desktop
Formatting a table in Microsoft Excel for use in ArcGIS—Help | ArcGIS for Desktop
and several other links elsewhere for the user to search out and explore
Richard,
I tried making all those values ones and it still didn't work. I do completely understand what you are saying, though.
I guess I'll try a few more changes to the table and see what happens.
Laura
Hi Daren,
Are you doing anything special to the table, like placing it in a geodatabase?
When I try to run the tool (after changing the values to all positives) it tells me that the input table does not exist or is not supported.
Just wondering what you did to make it work.
Laura:
Lines with 0 distance are points, not lines, and the tool does not support drawing points. You must assign a length value greater than 0 to those rows or eliminate those rows as Darren suggested. You don't have to necessarily delete those rows if you use a layer/table view with a selection of only the rows that have a length greater than 0 as the input to the tool. Potentially one approach to those rows with negative lengths is to select all of those rows and calculate the angle field to reverse the angle by adding 180 degrees to the angle (the tool should handle angle values that equal or exceed 360 degrees), then set the length to ABS([20yrSpread]) so that it is positive.
I assume your problem is now that you're trying to draw lines of distance zero.
I deleted those rows in your table, and it seems to work, although I'm not sure what your spatial reference is:
I altered my excel file (attached) so that the negative values were just zeros instead of a negative value and re-ran the bearing distance tool using the alt10yrSpread or the alt20yrSpread fields for the distance and it still didn't work.
Here's the error that I get in case that helps to figure out the problem:
Any other ideas on how to draw these lines besides manually drawing them in an editing session is greatly appreciated.
Looks like you have some negative numbers in your distance field (20yrSpread)...might be causing the tool to fail.
The Bearing Distance to Line tool fails due to the negative values in the 20yrSpread field. It is impossible to create a line with negative length. You either need to change all the values to their absolute value (positive), or create a new field and set it to the absolute value of the 20yrSrpread length. If you need to reverse the line direction for some reason after creating it based on the signed value of the length in the 20yrSpread field, that would happen in a separate step.
Signed in members can post, follow updates, and more. New here? Register a free account.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.