繼承DevExpress.XtraGrid.GridControl參考

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Drawing;
using System.Windows.Forms;
using DevExpress.XtraEditors.Repository;
namespace mygrdcol
{
    public partial class cts_basegrid : DevExpress.XtraGrid.GridControl
    {
        private mygrdcol.grc_textbox_lu grc_textbox;

        public cts_basegrid()
        {
            this.grc_textbox = new mygrdcol.grc_textbox_lu();
           
            this.BackColor = Color.Red;
            this.RepositoryItems.AddRange(new DevExpress.XtraEditors.Repository.RepositoryItem[] {            
            this.grc_textbox});
            ((System.ComponentModel.ISupportInitialize)(this.grc_textbox)).BeginInit();
            this.grc_textbox.Name = "grc_textbox";
            ((System.ComponentModel.ISupportInitialize)(this.grc_textbox)).EndInit();
        }
        
        private void InitializeComponent()
        {
            ((System.ComponentModel.ISupportInitialize)(this)).BeginInit();
            this.SuspendLayout();
            ((System.ComponentModel.ISupportInitialize)(this)).EndInit();
            this.ResumeLayout(false);
        }
    }
}

原文地址:https://www.cnblogs.com/luoyaoquan/p/2545302.html