We are working off version 7. I am attempting to use TranslateByDegree to move a pointshape a specified distance and degree. The distance it ends up moving the pointshape is not the same distance I specified.
In looking on the internet, I noticed this line in the version 8 change log. "Fixed a bug where the TranslateByDegree method returns incorrect result.". At this point we do not want to upgrade to version 8. Does anyone know if this fix is included in one of the version 7 builds? Or at the least a way to work around this issue?
For example when I run the following code:
var ps = new PointShape(vertexToMove);
ps.TranslateByDegree(distanceInMeters, angleToMove, GeographyUnit.Meter, DistanceUnit.Meter);
and then compare the original pointShape to the new pointShape, the distance is not the same as what I passed in. In my test, I passed in a value of 252.987 meters and it actually moved it 188.038.
TranslateByDegree Incorrect
Hi Scott,
Would you let us know which version you are referring? We test the map suite 7.0.0.0 and 7.0.0.339 with the codes like the screenshot, but seems the result is correct.
Would you try it in your end and let us know the results.
Thanks,
Troy
If I use the copyable haversine formula to check the distance, it comes up different.
As another example, I can tell it to move one mile on a 270 degree angle. When I look at the map and where it moved it too, it did not actually move it one mile.
Hi Scott,
I found out the original post for the bug fix on map suite 8.0 change log, Please have a look on it to see if that is the exact issue what you are facing now?
thinkgeo.com/forums/MapSuite…ault.aspx>
If it’s not, could you please attach some screenshots or a sample is better for us to recreate the issue? Also, I am wondering what’s the version you are referring?
Thanks,
Troy