I am experiencing the exact problem described above.
In order to open an infowindow after clicking a row in a grid view I have the following which works perfectly until any call back occurs. After that the javascript function is called but the infowindow does not open.
If I comment out the line mapcommand = GMap.ClearOverlays(true); from the callback everything works fine but obviously that is not a long term solution.
//Add javascript to handle the row click event
ClientScript.RegisterStartupScript(this.GetType(),"markerclick",
"<script language=javascript>" +
"function myclick(id){" +
"id = 'GMapmarker' + id;" +
"marker = reimers.map.GMap.getOverlay(id);" +
"GEvent.trigger(marker, 'click');" +
"}</script>");
//Add click event to gridview rows
if (GridView1.Rows.Count > 0)
{
int i;
for (i = 0; i < GridView1.Rows.Count; i++)
{
GridView1.Rows[i].Attributes.Add("onclick", GMap.CreateMapCallback("this.rowIndex", true));
}
}
//Handle the Callback
void GMap_ExternalCallback(string argument, ref string MapCommand)
{
string mapcommand = null;
if (argument == "filter")
{
//Get extents of the new viewport
double minx = (double)(Session["minx"]);
double miny = (double)(Session["miny"]);
double maxx = (double)(Session["maxx"]);
double maxy = (double)(Session["maxy"]);
createMarkers(minx, miny, maxx, maxy, ref mapcommand);
}
else
{
dt = Session["transactionlist"] as DataTable;
int recid = Convert.ToInt32(argument)-1;
recid = Convert.ToInt32(dt.Rows[recid]["transactionid"]);
mapcommand = "myclick('" + recid + "');";
}
MapCommand = mapcommand;
}