Calculate Slope and Profile

Discussion created by dcopple on Mar 2, 2011
Latest reply on Mar 2, 2011 by dcopple
I am trying to write some Javascript to use the ESRI profile service at http://sampleserver2.arcgisonline.com/ArcGIS/rest/services/Elevation/ESRI_Elevation_World/GPServer/ProfileService  I cannot find any examples on using this tool in the Javascript API.  I think I found one for flex, so am trying to break that apart.  I can calculate an x, y for a point.  Want to draw two points, figure out the distance, and the z values for the points to use in a slope calculation.  I want the slope calculation for input into other functions.  Does anyone have an idea how to calculate that z value, is it at the profile service, or is there another elevation service I should try to use.  This might be a nice addition to the ESRI geometry service which currently calculates x,y values for points, maybe the addition of a z value in that geometry would be nice too.