Esempio n. 1
0
        private IMap pMap = null; // ����pMap

        #endregion Fields

        #region Constructors

        public frmAttribute(IMap ppMap,int iLayerID)
        {
            InitializeComponent();
            pMap = ppMap;
            pLayerID = iLayerID;
            pfrmAttribute = this;
        }
Esempio n. 2
0
        public override void OnClick()
        {
            base.OnClick();
            ILayer pLyr = (ILayer)m_mapControl.CustomProperty;
            frmAttribute frmOpenAttributeTable=null;
            IFeatureLayer pFeatLyr = (IFeatureLayer)m_mapControl.CustomProperty;
            //��ȫ�ֱ���currentLayerName��ֵ��ǰ�����Ա��ͼ�������
            globalInfo.currentLayerName = pLyr.Name;

            for (int i = 0; i < m_mapControl.Map.LayerCount; i++)
            {
                if (m_mapControl.Map.get_Layer(i).Name == pFeatLyr.Name)
                {
                    frmOpenAttributeTable = new frmAttribute(m_mapControl.Map,i);
                    frmOpenAttributeTable.Show();
                    frmOpenAttributeTable.TopMost = true;
                    i = m_mapControl.Map.LayerCount;
                }
            }
        }