Пример #1
0
        void choosecolumnspage_GetSelectedInputOutputColumns(object sender, SelectedInputOutputColumnsArgs args)
        {
            this.ClearErrors();

            try
            {
                IDTSInput100 input = this.ComponentMetadata.InputCollection[0];
                IDTSInputColumnCollection100 inputColumnCollection = input.InputColumnCollection;

                foreach (IDTSInputColumn100 inputColumn in inputColumnCollection)
                {
                    SelectedInputOutputColumns element            = new SelectedInputOutputColumns();
                    IDTSVirtualInputColumn100  virtualInputColumn =
                        this.GetVirtualInputColumn(inputColumn);

                    element.VirtualInputColumn = new DataFlowElement(virtualInputColumn.Name, virtualInputColumn);
                    element.InputColumn        = new DataFlowElement(inputColumn.Name, inputColumn);

                    args.SelectedColumns.Add(element);
                }
            }
            catch (Exception ex)
            {
                this.ReportErrors(ex);
            }
        }
        /// <summary>
        /// Setting selected columns (input and output ones) to appropriate cells in the bottom grid
        /// </summary>
        /// <param name="selectedColumns"></param>
        /// <param name="row"></param>
        private void SetSelectedColumnsRow(SelectedInputOutputColumns selectedColumns, DataGridViewRow row)
        {
            DataGridViewCellCollection cells = row.Cells;

            SetGridCellData(cells[this.gridTextBoxInputColumn.Index], selectedColumns.VirtualInputColumn);
            SetGridCellData(cells[this.gridTextBoxOutputColumn.Index], selectedColumns.InputColumn);
        }
        /// <summary>
        /// Setting selected columns (input and output ones) to appropriate cells in the bottom grid
        /// </summary>
        /// <param name="selectedColumns"></param>
        /// <param name="row"></param>
        private void SetSelectedColumnsRow(SelectedInputOutputColumns selectedColumns, DataGridViewRow row)
        {
            DataGridViewCellCollection cells = row.Cells;

            SetGridCellData(cells[this.gridTextBoxInputColumn.Index], selectedColumns.VirtualInputColumn);
            SetGridCellData(cells[this.gridTextBoxOutputColumn.Index], selectedColumns.InputColumn);
        }
Пример #4
0
        void choosecolumnspage_GetSelectedInputOutputColumns(object sender, SelectedInputOutputColumnsArgs args)
        {
            this.ClearErrors();

            try
            {
                IDTSInput100 input = this.ComponentMetadata.InputCollection[0];
                IDTSInputColumnCollection100 inputColumnCollection = input.InputColumnCollection;

                foreach (IDTSInputColumn100 inputColumn in inputColumnCollection)
                {
                    SelectedInputOutputColumns element = new SelectedInputOutputColumns();
                    IDTSVirtualInputColumn100 virtualInputColumn =
                        this.GetVirtualInputColumn(inputColumn);

                    element.VirtualInputColumn = new DataFlowElement(virtualInputColumn.Name, virtualInputColumn);
                    element.InputColumn = new DataFlowElement(inputColumn.Name, inputColumn);

                    args.SelectedColumns.Add(element);
                }
            }
            catch (Exception ex)
            {
                this.ReportErrors(ex);
            }
        }