Example #1
0
        private void Initialize()
        {
            _application = this.Hook as IApplication;
            _mxdocument  = (IMxDocument)_application.Document;
            _map         = _mxdocument.FocusMap;
            _activeView  = _mxdocument.ActiveView;

            _utilitiesArcMap = new RS_Tools.Utilities.Utilities_ArcMap(_map);
            if (this.cboBuildingLayer.Items.Count > 0)
            {
                this.cboBuildingLayer.Items.Clear();
            }
            this.cboBuildingLayer.Items.AddRange(_utilitiesArcMap.PolygonLayerNames().ToArray());
            this.cboBuildingLayer.Items.AddRange(_utilitiesArcMap.PolylineLayers().ToArray());
            this.cboBuildingLayer.Items.AddRange(_utilitiesArcMap.PointLayerNames().ToArray());
            if (this.cboBuildingLayer.Items.Count > 0)
            {
                this.cboBuildingLayer.SelectedIndex = 0;
            }
        }