我在其他图标标记的每个for循环中编写代码,但是对于所有制作者的最后一个图标标记。
str_id = ds_picture.Tables["tbl"].Rows[0][1].ToString();
GapMarkerGoogle_MarkerActiev[] marker=new GapMarkerGoogle_MarkerActiev[200];
在for循环中
SqlDataAdapter da_picture2 = new SqlDataAdapter("select * from Mobile_Gps_Pictures where id=" + str_id + "", con_map_GPS);
DataSet ds_picture2 = new DataSet();
da_picture2.Fill(ds_picture2, "tbl");
Bitmap bmp = new Bitmap(GoogleMap.Properties.Resources._4shanbe);
if (bmp != null)
{
bmp.Dispose();
}
try
{
Byte[] byteBLOBData = new Byte[0];
byteBLOBData = (Byte[])(ds_picture2.Tables["tbl"].Rows[0][1]);
bmp = new Bitmap(ByteToImage(byteBLOBData));
}
catch
{
}
marker[i] = new GapMarkerGoogle_MarkerActiev(new PointLatLng(p2, p1), bmp);
markersOverlay.Markers.Add(marker[i]);
gMapControl1.Overlays.Add(markersOverlay);