public bool ShowGridViewRep() { this.ShowEditor(); BaseEdit rep = this.ActiveEditor; if (rep == null) { return(false); } switch (rep.ToString()) { case "DevExpress.XtraEditors.ImageComboBoxEdit": rep.Show(); if (!(rep as DevExpress.XtraEditors.ImageComboBoxEdit).IsPopupOpen) { (rep as DevExpress.XtraEditors.ImageComboBoxEdit).ShowPopup(); if ((rep as DevExpress.XtraEditors.ImageComboBoxEdit).Properties.Items.Count > 0 && (rep.EditValue == null || rep.EditValue.Equals(System.DBNull.Value))) { (rep as DevExpress.XtraEditors.ImageComboBoxEdit).SelectedIndex = 0; } } return(true); case "DevExpress.XtraEditors.TextEdit": case "DevExpress.XtraEditors.CalcEdit": rep.Focus(); rep.Select(); rep.SelectAll(); return(true); case "DevExpress.XtraEditors.LookUpEdit": case "ExtendControl.ExtRpyLookUpEdit": case "DevExpress.XtraEditors.MemoExEdit": //case "DevExpress.XtraEditors.ImageEdit": rep.Show(); rep.Select(); if (!(rep as DevExpress.XtraEditors.PopupBaseEdit).IsPopupOpen) { (rep as DevExpress.XtraEditors.PopupBaseEdit).ShowPopup(); } return(true); } return(false); }