Ejemplo n.º 1
0
        public SummaryResultsWindow(Hashtable sumResults)
        {
            InitializeComponent();
            this._sumResults = sumResults;

            ShapefileWorkspaceFactoryClass tempWSFactory = new ShapefileWorkspaceFactoryClass();
            IWorkspace tempWS = tempWSFactory.OpenFromFile(this._sumResults["workspace"].ToString(), 0);

            IFeatureWorkspace featureWS = tempWS as IFeatureWorkspace;

            // Bind dataset to the binding source
            TableWrapper tableWrapper = new ArcDataBinding.TableWrapper(featureWS.OpenTable(this._sumResults["table"].ToString()));

            this.SummaryTableGridView.DataSource = tableWrapper;

            // Create source.
            BitmapImage bi = new BitmapImage();

            // BitmapImage.UriSource must be in a BeginInit/EndInit block.
            bi.BeginInit();
            bi.UriSource = new Uri(this._sumResults["graph"].ToString(), UriKind.RelativeOrAbsolute);
            bi.EndInit();
            // Set the image source.
            this.SummaryGraph.Width  = bi.PixelWidth;
            this.SummaryGraph.Height = bi.PixelHeight;
            this.SummaryGraph.Source = bi;
        }
Ejemplo n.º 2
0
        public SummaryResultsWindow(Hashtable sumResults)
        {
            InitializeComponent();
            this._sumResults = sumResults;
            
            ShapefileWorkspaceFactoryClass tempWSFactory = new ShapefileWorkspaceFactoryClass();
            IWorkspace tempWS = tempWSFactory.OpenFromFile(this._sumResults["workspace"].ToString(), 0);

            IFeatureWorkspace featureWS = tempWS as IFeatureWorkspace;
            
            // Bind dataset to the binding source
            TableWrapper tableWrapper = new ArcDataBinding.TableWrapper(featureWS.OpenTable(this._sumResults["table"].ToString()));
            this.SummaryTableGridView.DataSource = tableWrapper;
            
            // Create source.
            BitmapImage bi = new BitmapImage();
            // BitmapImage.UriSource must be in a BeginInit/EndInit block.
            bi.BeginInit();
            bi.UriSource = new Uri(this._sumResults["graph"].ToString(), UriKind.RelativeOrAbsolute);
            bi.EndInit();
            // Set the image source.
            this.SummaryGraph.Width = bi.PixelWidth;
            this.SummaryGraph.Height = bi.PixelHeight;
            this.SummaryGraph.Source = bi;
        }
Ejemplo n.º 3
0
        public AttrTableWindow(ITable attrTable)
        {
            InitializeComponent();
            // Bind dataset to the binding source
            TableWrapper tableWrapper = new ArcDataBinding.TableWrapper(attrTable);
            //this.AttrTableGrid.ItemsSource = tableWrapper;
            //this.AttrTableGrid.Items.Refresh();  
            this.AttrTableGridView.DataSource = tableWrapper;

        }
Ejemplo n.º 4
0
        public AttrTableWindow(ITable attrTable)
        {
            InitializeComponent();
            // Bind dataset to the binding source
            TableWrapper tableWrapper = new ArcDataBinding.TableWrapper(attrTable);

            //this.AttrTableGrid.ItemsSource = tableWrapper;
            //this.AttrTableGrid.Items.Refresh();
            this.AttrTableGridView.DataSource = tableWrapper;
        }