예제 #1
0
        private void PopulateCompetitor()
        {
            ProjectInfoBO CompBO = new ProjectInfoBO()
            {
                i_CostCentreId = i_CostCentreId
            };

            dtCom = new DataTable();
            dtCom = ProjectInfoDL.SelectCompetitor(CompBO);
            grdCompetitor.DataSource = dtCom;
            grdCompetitorView.PopulateColumns();
            grdCompetitorView.Columns["ProjectId"].Visible      = false;
            grdCompetitorView.Columns["CompetitorId"].Visible   = false;
            grdCompetitorView.Columns["CompetitorName"].Visible = false;
            grdCompetitorView.Columns["ProjectName"].OptionsColumn.AllowEdit         = false;
            grdCompetitorView.Columns["Sel"].AppearanceHeader.TextOptions.HAlignment = DevExpress.Utils.HorzAlignment.Center;

            ChkEditComp.CheckedChanged += (sender, e) =>
            {
                if (Convert.ToBoolean(ChkEditComp.Editable) == true)
                {
                    ChkEditComp.ValueChecked = true;
                }
            };

            grdCompetitorView.Appearance.HeaderPanel.Font      = new Font(grdCompetitorView.Appearance.HeaderPanel.Font, FontStyle.Bold);
            grdCompetitorView.Appearance.FocusedCell.BackColor = Color.Teal;
            grdCompetitorView.Appearance.FocusedCell.ForeColor = Color.White;
            grdCompetitorView.Appearance.FocusedRow.ForeColor  = Color.Black;
            grdCompetitorView.Appearance.FocusedRow.BackColor  = Color.Teal;

            grdCompetitorView.OptionsSelection.EnableAppearanceHideSelection = false;
        }
예제 #2
0
 public static DataTable SelectCompetitor(ProjectInfoBO CompBO)
 {
     return(ProjectInfoDL.SelectCompetitor(CompBO));
 }