Hello all! The company I am currently working for has decided to migrate from ArcGIS 9.3 to 10.0 recently and we are having difficulty using a few of our Arc 9.3 models that utilize the Calculate Field tool. They were written in VBA and I need to get them to work using VBScript. The following bit of code is intended to calculate the x coordinate of the centre of a harvesting block and put it in a field.
Field Name: xcoord
Expression Type: VB
Code Block:Dim dblX as Double Dim pArea as IArea Set pArea = [Shape] dblX = pArea.Centroid.X
Use Python if you want access to geoprocessing functionality, including feature geometry....If you have VBA code from past releases that use ArcObjects, you will need to modify your calculations to work in 10.0.