private void Operate(string LayerName,string WhereClause) { var cmd = new ClickSearchTool(LayerName, WhereClause, axMapControl1, this); cmd.OnCreate(axMapControl1.Object); axMapControl1.CurrentTool = (ITool)cmd; }
private void BtnRoadBus_Click(object sender, EventArgs e) { var RoadFeatureLayer = GetFeatureLayer(RoadName.GetLayer()); var BusLineFeatureLayer = GetFeatureLayer(BusLineName.GetLayer()); if (RoadFeatureLayer.Visible == false||BusLineFeatureLayer.Visible==false) { RoadFeatureLayer.Visible = true; BusLineFeatureLayer.Visible = true; MapRefresh(); } var cmd = new ClickSearchTool(RoadName.GetLayer(), RoadFilterWhereClause, this.axMapControl1, this, true); cmd.OnCreate(axMapControl1.Object); axMapControl1.CurrentTool = (ITool)cmd; }
private void ClickSearchBase(string LayerName, string WhereClause) { this.operateMode = OperateMode.None; var cmd = new ClickSearchTool(LayerName,WhereClause, this.axMapControl1, this); cmd.OnCreate(axMapControl1.Object); axMapControl1.CurrentTool = (ITool)cmd; }