Function CCGridInverse(refPoint As IGeodeticPoint, contactPoint As IGeodeticPoint) As String
function CCGridInverse(const refPoint: IGeodeticPoint; const contactPoint: IGeodeticPoint): WideString;
The CCGridInverse method calculates the Cartesian Coordinate Grid (CCG) string that describes the location of a contact point relative to a reference point. The method takes two arguments, the first of which is the reference point, and the second of which is the contact point. It returns a string that will hold the resulting CCG string.
If three-dimensional GeodeticPoints are used with this method, the Height coordinates will be ignored. The Height of the points will be assumed to be 0 so that the calculations will occur on the surface of the Ellipsoid.
Sub Ellipsoid_CCGridInverse(ell As Ellipsoid)
Dim referencePt As New GeodeticPoint
Dim contactPt As New GeodeticPoint
Dim ccgString As String
referencePt.Longitude.InDegrees = -76
referencePt.latitude.InDegrees = 45
contactPt.Longitude.InDegrees = -76.04
contactPt.latitude.InDegrees = 44.85
ccgString = ell.CCGridInverse(referencePt, contactPt)
End Sub
procedure Ellipsoid_CCGridInverse(ell : Ellipsoid);
var
referencePt : GeodeticPoint;
contactPt : GeodeticPoint;
ccgString : WideString;
begin
referencePt := CoGeodeticPoint.Create;
referencePt.Longitude.InDegrees := -76;
referencePt.Latitude.InDegrees := 45;
contactPt := CoGeodeticPoint.Create;
contactPt.Longitude.InDegrees := -76.04;
contactPt.latitude.InDegrees := 44.85;
ccgString := ell.CCGridInverse(referencePt, contactPt);
end;