示例#1
0
        /// <summary>
        /// Initialize a new data table
        /// </summary>
        /// <param name="AssociatedPropertyPage">The property page associated with the table</param>
        /// <param name="miniMap">The mini-map associated with the table</param>
        /// <param name="nMap">The network map associated with the table</param>
        /// <param name="violView">The violation view assocaited with the table</param>
        public MM_Data_Table(MM_Property_Page AssociatedPropertyPage, MM_Network_Map_DX nMap, MM_Violation_Viewer violView, MM_Mini_Map miniMap)
        {
            this.nMap    = nMap;
            this.miniMap = miniMap;
            this.AssociatedPropertyPage   = AssociatedPropertyPage;
            this.AllowUserToAddRows       = false;
            this.AllowUserToResizeColumns = true;
            this.violView = violView;
            this.AllowUserToResizeRows   = true;
            this.AllowUserToOrderColumns = true;
            if (MM_Server_Interface.Client != null)
            {
                this.EditMode = DataGridViewEditMode.EditProgrammatically;
            }
            else
            {
                this.EditMode          = DataGridViewEditMode.EditOnEnter;
                this.CellValueChanged += new DataGridViewCellEventHandler(Data_Table_CellValueChanged);
            }


            this.DataError                 += new DataGridViewDataErrorEventHandler(Data_Table_DataError);
            this.BackgroundColor            = Color.Black;
            this.DefaultCellStyle.BackColor = Color.Black;
            this.DefaultCellStyle.ForeColor = Color.White;
            this.RowHeadersVisible          = false;
            this.AllowUserToResizeRows      = false;
        }
示例#2
0
 /// <summary>
 /// Assign a property page to the search results form
 /// </summary>
 /// <param name="propPage"></param>
 public void SetPropertyPage(MM_Property_Page propPage)
 {
     this.propPage = propPage;
 }