private void wpfMap1_MapClick(object sender, MapClickWpfMapEventArgs e) { int width = (int)shapeLayer.GetBoundingBox().Width; double n = (int)e.WorldLocation.X / width; double x = e.WorldLocation.X - n * width; PointShape point; if (e.WorldLocation.X > 0) { if (x > width / 2) { point = new PointShape(x - width, e.WorldLocation.Y); } else { point = new PointShape(x, e.WorldLocation.Y); } } else { if (x < width / -2) { point = new PointShape(x + width, e.WorldLocation.Y); } else { point = new PointShape(x, e.WorldLocation.Y); } } Collection features = shapeLayer.QueryTools.GetFeaturesContaining(point, ReturningColumnsType.AllColumns); if (features.Count > 0) { popupOverlay.Popups.Add(new Popup(e.WorldLocation) { Content = features[0].ColumnValues["CNTRY_NAME"] }); } wpfMap1.Refresh(); }