예제 #1
0
        private void button6_Click(object sender, EventArgs e)
        {
            IGxDialog                 dlg     = new GxDialogClass();
            IGxObjectFilter           filter1 = new GxFilterFeatureClassesClass();
            IGxObjectFilter           filter2 = new GxFilterAnnotationFeatureClassesClass();
            IGxObjectFilterCollection filters = dlg as IGxObjectFilterCollection;

            filters.AddFilter(filter1, true);
            filters.AddFilter(filter2, false);
            IEnumGxObject selection;

            if (dlg.DoModalOpen(this.Handle.ToInt32(), out selection))
            {
                IGxObject gobj = selection.Next();
                if (gobj != null)
                {
                    this.tbxDataSource.Text = gobj.FullName;
                    m_fcName = gobj.InternalObjectName;
                    this.tbxCacheName.Text = gobj.BaseName;
                }
            }
        }
예제 #2
0
        private void button6_Click(object sender, EventArgs e)
        {
            IGxDialog dlg = new GxDialogClass();
            IGxObjectFilter filter1 = new GxFilterFeatureClassesClass();
            IGxObjectFilter filter2 = new GxFilterAnnotationFeatureClassesClass();
            IGxObjectFilterCollection filters = dlg as IGxObjectFilterCollection;
            filters.AddFilter(filter1,true);
            filters.AddFilter(filter2,false);
            IEnumGxObject selection ;
            if(dlg.DoModalOpen(this.Handle.ToInt32(), out selection))
            {
                IGxObject gobj = selection.Next();
                if(gobj!=null)
                {
                    this.tbxDataSource.Text = gobj.FullName;
                    m_fcName = gobj.InternalObjectName;
                    this.tbxCacheName.Text = gobj.BaseName;
                }
            }

        }