I need help from someone to translate a small piece of code from VBA to Python, due to the fact that the company I am working for has upgraded from ArcGIS 9.3.1 to 10.0 and VBA is no longer supported. The code block is as follows:
static x0 as double, y0 as double dim pPoint as IPoint set pPoint = [Shape] x = pPoint.X y = pPoint.Y d = sqr((x-x0)^2 + (y-y0)^2) x0 = x y0= y
This is used with the calculate field tool inside model builder and as far as I can tell retrieves info about two points and calculates the difference in distance between them. I have attempted a few translations on my own with little success using
Unfortunately my knowledge is lacking and I need some assistance. If you are able to help, that would be greatly appreciated!