[Tutor] point distance analysis

Alan Gauld alan.gauld at btinternet.com
Mon Apr 29 15:27:01 CEST 2013


On 28/04/13 11:01, Ramy Brooks wrote:
> Hi I am looking for suggestions to fix my script to add an additional field.
>

This looks like is more of an arcpy question than a Python one. I 
suggest you try the arcpy support fora. Meantime a quick comment on your 
code...


>
> def main():
>      pass
>
> if __name__ == '__main__':
>      main()

This code is pointless, it just calls a function that does nothing.
It would make some sense if you had the code within your 'try' section 
inside the main() function but as it stands you might as well just 
delete it.


-- 
Alan G
Author of the Learn to Program web site
http://www.alan-g.me.uk/



More information about the Tutor mailing list