[/
Sub PlotPoints(A As Int)
Dim AveY, AveX As Double
Dim cp As CameraPosition
Dim Co As CircleOptions
File.MakeDir(File.DirRootExternal & "/CEASER/","Data/Projections")
Co.Initialize
'Dim BitMap1 As Bitmap = LoadBitmapResize(File.DirRootExternal & "/CEASER/DATA/", "Point.png",8dip,8dip,True)
Try
gmap.Clear
If CGlobals.CoordCode=1 Then
'Site Coords
Dim rs As ResultSet = CGlobals.sql1.ExecQuery("SELECT Name, East, North, Elevation, Description FROM SCoords")
else if CGlobals.CoordCode=2 Then
'Global Coords
Dim rs As ResultSet = CGlobals.sql1.ExecQuery("SELECT Name, East, North, Elevation, Description FROM GCoords")
Else
'Job Coords
Dim rs As ResultSet = CGlobals.sql1.ExecQuery("SELECT Name, East, North, Elevation, Description FROM Coords")
End If
i=0: AveY=0: AveX=0
Do While rs.NextRow
Dim row(5) As Object
row(0) = rs.GetString("Name")
row(1) = NumberFormat2(rs.GetDouble("East"),1,3,3,False)
row(2) = NumberFormat2(rs.GetDouble("North"),1,3,3,False)
'row(3) = NumberFormat2(rs.GetDouble("Elevation"),1,3,3,False)
Geo.get_point_from_local(row(1),row(2))
Co.StrokeWidth(2)
' co.Center2(Engine.Lat,Engine.Lon).Radius(Radius.SelectedItem).FillColor(Colors.White).StrokeColor(Colors.DarkGray)
' gmapextra.AddCircle(gmap,co)
'gmap.AddMarker(Engine.Lat,Engine.Lon, "New Marker")
'gmap.AddMarker3(Engine.lat,Engine.Lon,row(0),Bitmap1)
i=i+1
AveY=AveY+row(1)
AveX=AveX+row(2)
Loop
rs.Close
If (AveY<>0 Or AveX<>0) And A=0 Then
'Zoom in to center of points
AveY=AveY/i
AveX=AveX/i
Convert(row(1),row(2),34)
' Engine.Hart94_YX(AveY,AveX,19)
' cp.Initialize(Engine.Lat,Engine.Lon, 10)
' gmap.MoveCamera(cp)
'ConvertLatLong
End If
Catch
Log(LastException)
End Try
End Sub
]